new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

OWASP Cheat Sheets · all subjects

ai agent security/memory security

2 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

Memory security: validation, isolation, and expiration

Validate and sanitize data before storing in agent memory. Implement memory isolation between users and sessions. Set memory expiration and size limits. Audit memory contents for sensitive data before persistence. Use cryptographic integrity checks for long-term memory.

Secure memory implementation: constraints and patterns

SecureAgentMemory should enforce: MAX_MEMORY_ITEMS = 100 (limit number of stored items), MAX_ITEM_LENGTH = 5000 (truncate oversized content), MEMORY_TTL_HOURS = 24 (expire old memories). Before storing, scan content for sensitive data patterns (SSN: r'\b\d{3}-\d{2}-\d{4}\b', Credit card: r'\b\d{16}\b', Passwords: r'password\s*[:=]\s*\S+', API keys: r'api[_-]?key\s*[:=]\s*\S+') and redact. Sanitize injection attempts. Create entries with 'content', 'type', 'timestamp', 'user_id', and 'checksum' (SHA256 of content + user_id + encryption_key). When retrieving, validate timestamp against MEMORY_TTL_HOURS cutoff and verify checksum integrity.

Give your agent this brain