Local Security & Keychain
Credential Storage
Maktabi Agent implements enterprise-grade OS credential management:
- Windows: Windows Credential Manager (
keytarvia DPAPI encryption). - macOS: Apple Keychain Services.
- Linux: Secret Service API / libsecret.
Your desktop session token (mk_dsk_...) is never stored in plain text configuration files, local storage, or environment files.
Token Hashing Contract
When a token is generated:
- The plaintext token is generated using 32 cryptographically secure random bytes.
- The server computes the SHA-256 digest:
hash = sha256(token). - Only the SHA-256 digest is stored in the database table
maktabi.desktop_tokens. - Even in the event of a database compromise, plaintext tokens cannot be reconstructed.
Offline Grace Period
Maktabi includes a 14-day offline grace period. If your internet connection drops while traveling or working in court:
- You retain access to your local workspace, existing drafts, and offline templates.
- When reconnected, the client resynchronizes credit consumption with the cloud ledger.