# Security notes

## Implemented controls

- Together credentials remain server-side.
- HTTP-only, SameSite=Lax sessions; Secure cookies are configurable for HTTPS.
- CSRF token required for authenticated mutations.
- Content Security Policy and restrictive browser-policy headers.
- Randomised stored filenames and ownership checks on every file/message/job route.
- Upload size and attachment-count limits.
- ZIP traversal, absolute-path, Windows-drive, symbolic-link, member-count, member-size, aggregate-size and suspicious-ratio blocking.
- SHA-256 integrity metadata.
- Owner-only administration and append-only audit records.
- Detailed readiness information is shown only to an authenticated session.

## Known security gaps

- File bodies are not encrypted at rest.
- IndexedDB drafts are not encrypted.
- No malware scanner is integrated.
- Authentication has no rate-limit store, multi-factor authentication or account recovery flow.
- The local launcher is not a complete hardened Nginx/systemd deployment.
- Code Interpreter trusts Together’s managed sandbox contract; KIMU does not expose a local shell.

Do not expose the development server publicly. Use Gunicorn behind HTTPS and complete the production-hardening phase before internet-facing deployment.
