Security overview
Purpose
This document describes Verin’s current security architecture and control posture for SOC 2, HIPAA, and ISO 27001 readiness. It is evidence-driven and avoids certification claims.
Detailed control mappings (SOC 2 / HIPAA / ISO 27001) and the underlying control-evidence index are maintained internally and shared with customers under NDA via the evidence-request process.
Security Architecture Summary
Verin uses a layered control model:
- Identity and session controls (Auth0 or local JWT)
- Authorization and tenant/workspace access controls (RBAC + segment checks)
- Data protection controls (token encryption at rest, TLS in hosted deployments, PII redaction pipeline)
- Audit and traceability controls (immutable audit logs, exportable trail)
- Deployment-mode isolation controls (cloud Weaviate/PostgreSQL and desktop ChromaDB/SQLite modes)
Trust Boundaries
- Client to API boundary
- Browser/desktop client sends bearer token to API endpoints.
- API enforces identity and role/permission checks.
- API to persistence boundary
- Relational DB stores tenant-scoped records and audit logs.
- Vector stores hold document chunks and metadata with tenant-scoped filters/collections.
- API to third-party boundary
- Auth0 (when enabled) for identity.
- OAuth providers (Google/Dropbox/OneDrive) for import.
- LLM/vector services according to runtime configuration.
- Platform-admin boundary
- Platform admin can access cross-tenant metadata management endpoints.
- Product intent is to restrict platform admins from tenant business data content.
Identity, Authentication, and Authorization
- Auth modes:
- Auth0 JWT verification path.
- Local JWT mode with bcrypt password verification.
- Authorization:
- Role-permission mapping in service-level RBAC.
- Explicit permission checks on sensitive routes.
- Platform admin gate for
/platform/*and related administrative boundaries.
- Segment/workspace access:
- Optional segment restrictions with fallback unrestricted behavior when no grants exist.
Reference controls: AC-01, AC-02, AC-03, AC-04, AC-05.
Tenant Isolation Model
- Tenant scoping is implemented at model/query level using
tenant_idacross tenant-scoped records. - Document vectors include tenant metadata and search filters.
- Desktop mode uses per-tenant collection naming for vector storage.
Reference controls: AC-03, DP-02.
Audit and Monitoring Controls
- Audit records are generated for authentication/session and permission-sensitive operations.
- Immutability protections:
- PostgreSQL trigger-based immutability migration available.
- SQLite event-listener enforcement registered at runtime.
- Tamper-evidence: each audit row carries a SHA-256
integrity_hashstamped at insert, so an altered row can be detected by recomputing its hash. The hash is not keyed or chained, and no scheduled verification runs yet. - Audit export endpoints support CSV/PDF generation for regulated traceability workflows.
Reference controls: AU-01, AU-02, AU-03.
Data Protection and Cryptography
- OAuth tokens are encrypted at rest using Fernet before DB storage.
- Transport security depends on deployment (
httpsin hosted mode; local desktop mode may be loopback/local network scoped). - PII redaction service (Presidio-backed with regex fallback) is integrated into ingestion flows.
Reference controls: DP-01, DP-03, PR-01, PR-02.
Deployment Modes
Cloud mode
- PostgreSQL + Weaviate.
- External identity provider support.
- Audit immutability can be enforced with DB triggers.
Desktop/self-contained mode
- SQLite + ChromaDB.
- Local auth option.
- SQLite audit immutability enforced via SQLAlchemy event listeners.
Control Posture Snapshot
- Implemented: RBAC permissions, tenant-scoped query model, OAuth token encryption at rest, audit immutability mechanisms, audit tamper-evidence integrity hash, electronic-signature immutability with content-manifest binding, PII redaction service, audit export, CORS explicit allowlist, structured logging with credential and token redaction, TLS in transit (cloud: Azure-terminated; desktop: local-only by design), API rate limiting (brute-force on login, per-user limits on LLM endpoints).
- User-entered prompts and chat queries may be retained in operational logs and tenant-scoped chat history for debugging and conversation context. Logging hygiene for prompt content (so PHI / confidential document detail is not over-retained in operational telemetry) is being hardened — see the privacy posture for the maturing controls.
- Partial: dev auth bypass controls, formal retention policy, incident/BCDR documentation.
- Planned: formalized governance artifacts.
Current Gaps
- Dev auth bypass controls are not fully locked down for production environments.
- Brute-force/rate-limit controls are not consistently enforced at API boundary.
- Formal security operations artifacts (incident response, retention schedule, BCDR test evidence) are incomplete.
Roadmap
- 2026-Q2: Complete security hardening baseline for auth, CORS, abuse controls.
- 2026-Q2: Publish and maintain control evidence index with quarterly review cadence.
- 2026-Q3: Expand operational governance pack (incident handling, backup validation, restoration tests).