# Security Policy Monolith stores provider API keys and private conversation history on the local machine. Treat the machine account that runs it as security-sensitive. ## Reporting a vulnerability Do not open a public issue containing API keys, endpoint credentials, private conversations, exploit details, or personal data. Contact the repository maintainer privately and include only the minimum reproduction information required. ## Operational guidance - Protect the Windows user account: credential encryption is scoped to the signed-in user via DPAPI, so anyone who can run code as that user can read stored keys. - Keep the `~/.Monolith` directory out of shared folders, sync services, and backups that other people can read; the credentials file and conversation database live there. - Configure only provider endpoints you trust; Monolith sends conversation content directly to the endpoints you configure and nowhere else. - Rotate any API key that appears in a screenshot, log excerpt, issue, or commit. - Keep Rust, Node.js build tooling, and npm dependencies current when building from source; review `cargo audit` and `npm audit` results. ## Credential exposure If a provider API key is exposed: 1. Revoke or rotate the key in the provider's console. 2. Open Monolith's model configuration, paste the new key, and save. 3. Remove the exposed value from logs, screenshots, issues, commits, and backups where possible. ## Current protections - API keys are encrypted with Windows DPAPI (user scope, no UI prompts) before being written to `~/.Monolith/credentials.json`; the SQLite database stores only a key reference and the last four characters. - Logs, error messages, connection-test summaries, and diagnostic exports redact `Authorization`, `x-api-key`, cookie values, and key-bearing URL query parameters; diagnostic exports never include the credentials file. - Protocol-forced and authentication headers (`Authorization`, `x-api-key`, `anthropic-version`, `Content-Type`) cannot be overridden by provider- or model-level custom headers. - Provider brand SVGs pass a strict element allowlist before storage or rendering: no scripts, event attributes, external references, `foreignObject`, or data URIs. - The webview enforces `script-src 'self'`; the code editor and all frontend assets are bundled locally, and no executable code is fetched at runtime. - Tauri capabilities are minimal: core defaults plus opening files and dialogs, restricted to the main window. - All SQL statements are parameterized. - Optional local sign-in lock with PIN, failed-attempt lockout, and an isolated guest mode. - The bundled local-model runtime is fetched from the upstream project's official release at a pinned version, and its MIT license text ships alongside it.