Skip to main content
DraftCounsel™

Trust

Procurement and trust package

Generated from the registries the code enforces: a buyer reads the same truth the code holds, and the trust index on /security dates it.

Generated from the registries by npm run registers (src/lib/lifecycle/procurement.ts); the drift law fails when this document differs from its sources. A buyer reads the same truth the code enforces.

Evidence status

DraftCounsel is not SOC 2 certified and holds no security certification. The controls below are implemented and each names its evidence in the repository; control evidence is being assembled toward a SOC 2 Type I examination, which has not been performed.

Controls

Controls
ControlStatusOwnerEvidence
Matter-scoped authorization with deny-precedence wallsimplementedplatform engineeringsrc/lib/authorization.ts
Professional approval gated on a verified licence recordimplementedplatform engineeringsrc/lib/attorney/licence.ts
Append-only adjudication trail; one approval per exact versionimplementedplatform engineeringsrc/lib/approvals/semantics.ts
Export classes with no-override checks and receiptsimplementedplatform engineeringsrc/lib/export/classes.ts
Egress allow-list: every sub-processor declared in code with its purpose and data classesimplementedplatform engineeringsrc/lib/egress/vendors.ts
Content-free operational logs and tracesimplementedplatform engineeringsrc/lib/observability.ts
Security headers with a nonce Content-Security-Policyimplementedplatform engineeringsrc/lib/http-security.ts
Secret scanning and dependency audit as required checks on every pushimplementedplatform engineering.github/workflows/ci.yml
Deletion requests with receipts; legal holds beat deletion and carry review datesimplementedthe owner, with platform engineeringsrc/lib/lifecycle/lifecycle-map.ts
Restore rules: deleted, revoked and superseded records never return to serviceimplementedplatform engineeringsrc/lib/lifecycle/restore.ts
Deprovisioning across every credential classimplementedplatform engineeringsrc/lib/lifecycle/deprovision.ts
Incident process with per-firm, content-free noticesimplementedthe ownerdocs/runbooks/INCIDENT.md
Release provenance and the documented release ritualimplementedplatform engineeringdocs/runbooks/RELEASE-RITUAL.md
Written refusals, each with an enforcing symbol and a negative testimplementedplatform engineeringsrc/lib/refusals/catalogue.ts
Offboarding: a removal ends the workspace membership, then the member’s mailbox tokens, their Clio link and any running timer, each written to the administration trailimplementedplatform engineeringsupabase/migrations/20261003230000_unified_member_offboarding.sql
The firm’s administration trail, append-only and exported by date by a firm owner or adminimplementedplatform engineeringsrc/app/api/firm/action-history/route.ts
Membership and role changes refuse a session whose enrolled authenticator is not yet verifiedimplementedplatform engineeringsrc/app/api/firm/route.ts
Role templates with least privilege across the APIs, search, exports and background jobs, each boundary naming where it is enforced and what proves itimplementedplatform engineeringsrc/lib/lifecycle/role-templates.ts
The client intake: the draft, the files and the submission each open with their own switch, and each store checks the link again at every write; held under legal holds and removed with the matter content; files kept in private storage under a server-owned path, checked by their first bytes, size and digest, shown as received and not scanned, and opened by the firm through five-minute linksimplementedplatform engineeringdocs/unified-workstation/INTAKE-UPLOAD-THREAT-NOTES.md
Public claims derived from one registryimplementedthe ownersrc/lib/claims-registry.ts
An independent assessment scoped to ASVS-selected controlsplannedthe ownerrecord: M18-05 assessment scope
A SOC 2 Type I examinationplannedthe ownerrecord: not started; no report exists
single sign-on (SAML or OIDC)demand-gatedthe ownerrecord: added when a supported firm needs it
automated provisioning (SCIM)demand-gatedthe ownerrecord: added when a supported firm needs it
firm-required multi-factor authenticationdemand-gatedthe ownerrecord: added when a supported firm needs it
device and session review for administratorsdemand-gatedthe ownerrecord: added when a supported firm needs it

Data flow and sub-processors

Every outbound destination is declared in code; a request to anything else is refused before it leaves.

Data flow and sub-processors
Sub-processorPurposeData classes
anthropicPrimary model: drafting, review, redline, counsel, verification, claim extraction, synthesis.client-content, query
openaiThe OpenAI engines (ChatGPT-5.6 Sol, included; ChatGPT-6 Astra, per-document upgrade) and the second engine of the dual run; receives the same grounded prompt as the primary, with store: false.client-content, query
resendTransactional email: access codes, share notices, winback, support receipts.contact
dropbox-signE-signature delivery of an approved document to named signers.client-content, contact
proofRemote online notarization of an approved document.client-content, contact
squareHosted checkout, order retrieval and payment reconciliation.payment, contact
brave-searchOpen-web exemplar discovery: query strings derived from the document type and venue, never document text.query
courtlistenerRECAP and opinion search (queries) and the citation lookup (the cite-check posts the document text it checks).client-content, query
unicourtLicensed exemplar connector (dormant until keyed): search queries and document-text reads.query
trellisLicensed exemplar connector (dormant until keyed): search queries and document-text reads.query
statute-httpOperator-configured statute endpoint (dormant until STATUTE_API_URL is set): jurisdiction, family, document type and topics only.query
florida-clerksThe Broward and Miami-Dade clerks’ docket APIs (dormant until a clerk’s key is set and the owner overrules the key-in-URL law): the case number, with the clerk’s key in the address as the clerk requires (F-1-01, 2026-10-10: the pull reached them outside the gate).query
clioClio Manage, the firm’s own practice system (dormant until a firm connects its account): OAuth code exchange, token renewal and revocation, the connected user’s identity, matter searches and links, the firm’s subscriptions to matter, bill and payment changes, and the approved document versions a firm owner or admin sends to the linked Clio matter (the document’s name to Clio, its bytes to Clio’s storage host confirmed for the region), and the approved time and expense entries a firm owner or admin sends to the linked Clio matter as activities (the member’s description is client content), and reads of the linked matters’ bills and trust balances, in the firm’s Clio region (WK-32-01, WK-32-02, WK-33-02, WK-33-03, WK-33-04, WK-33-05).none, query, client-content
microsoftMicrosoft 365, a member’s own mailbox, calendar and drive (dormant until the firm allows it and the member connects): the sign-in code exchange and token renewal at the Microsoft identity platform, the member’s own identity, searches of their own mail (the words they typed), and reading the messages and attachments they choose to bring into a matter and the calendar events they link to one, and searches of their own OneDrive and the files shared with them (the words they typed) and the files they choose to bring into a matter, whose bytes come from the short-lived download address on the tenant’s SharePoint host. Read only; nothing of the firm’s client content is sent and nothing is written to the mailbox or a drive (WK-32-04).none, query
googleGoogle, a member’s own Gmail, Calendar and Drive (dormant until the firm allows it and the member connects): the sign-in code exchange, token renewal and revocation, the member’s own identity, searches of their own mail (the words they typed), reading the messages and attachments they choose to bring into a matter, their calendar events in a window they choose and the events they link to one, and Drive searches (the words they typed) and the files they choose to bring into a matter. Read only; nothing of the firm’s client content is sent and nothing is written to the mailbox, the calendar or Drive (WK-32-04).none, query
public-webPublic exemplar, court-form and robots reads: https GET with no body, policed by publisher policy, robots and redirect hops.none

Access model

Access is decided per matter by one authorization function, with walls that deny regardless of role; approval needs a verified licence record. Removal reaches every credential class:

  • session (auth.sessions): revoke; every live session ends through the global sign-out, refresh tokens included; the next request is unauthenticated.
  • api-key (api_keys): revoke; keys reach only what their owner can, so an owner removed means every key revoked.
  • external-agent-grant (external_agent_grants): revoke; an agent acting for the user loses its grant with the user.
  • connector-account (connector_accounts): transfer-or-revoke; a firm connector the user connected is revoked unless a firm administrator takes it over by name.
  • scheduled-job (workspace_runs): pause; queued work the user launched is paused, not run under a removed identity.
  • portal-grant-issued (client_portal_grants): keep-firm-owned; a client grant belongs to the matter; it stays live for the client and the firm reassigns the matter.
  • share-issued (share_grants): keep-firm-owned; a share of an approved version belongs to the matter; the firm reviews it on reassignment.
  • intake-grant-issued (matter_intake_grants): keep-firm-owned; an intake link belongs to the matter; the firm reviews it on reassignment.
  • mailbox-token (mailbox_credentials): revoke; the member’s own mailbox tokens for the firm are deleted and the connection marked revoked; the consent given to the provider is theirs to withdraw there.
  • connector-user-link (connector_user_mappings): revoke; the link naming the member’s Clio user is removed, so nothing is sent to Clio as them.
  • running-timer (firm_time_entries): pause; a timer left running is paused at the moment of removal; the entries stay the firm’s for review.

Role templates and least privilege

Four firm roles and the client. "may open" means the matters the role and the ethical walls allow; a wall denies whatever the role. Each row names where the boundary is enforced; src/lib/lifecycle/role-templates.ts also names what proves it.

Role templates and least privilege
CapabilityAreaOwnerAdminAttorneyParalegalClientEnforced in
Read a matter and its workAPImay openmay openmay openmay opennosrc/lib/authorization.ts
Invite, change the role of and remove membersAPIyesyesnononosrc/lib/firm/membership.ts
End a removed member’s remaining access (mailbox, Clio link, running timers)APIyesyesnononosupabase/migrations/20261003230000_unified_member_offboarding.sql
Define, order, archive and retype the firm’s fieldsAPIyesyesnononosupabase/migrations/20261003220000_unified_custom_fields.sql
Record a matter’s or client’s field valuesAPImay openmay openmay openmay opennosupabase/migrations/20261003220000_unified_custom_fields.sql
Review time and expenses and send them to ClioAPIyesyesrecords and submits ownrecords and submits ownnosupabase/migrations/20261003170000_unified_firm_time_entries.sql
See billing amounts and trust balances from ClioAPIyesyesyesnonosupabase/migrations/20261003190000_unified_clio_billing_status.sql
Subscribe to Clio’s matter, bill and payment changesAPIyesyesnononosupabase/migrations/20261003200000_unified_clio_billing_events.sql
Allow a mailbox provider for the firm; connect one’s own mailboxAPIallows; connects ownallows; connects ownconnects ownconnects ownnosupabase/migrations/20261003140000_unified_mailbox_microsoft.sql
The client portalAPIpublishes to clientspublishes to clientspublishes to clientsnoown published items onlysupabase/migrations/20260925050000_m17_client_boundary.sql
Search the matter directorySearchmay openmay openmay openmay opennosupabase/migrations/20260927134912_unified_client_matter_directory.sql
Find matters or clients by a firm fieldSearchmay open; every clientmay open; every clientmay open; own clientsmay open; own clientsnosrc/app/api/firm/custom-fields/find/route.ts
Operational reports and their exportExportmay openmay openmay openmay opennosrc/app/api/firm/reports/route.ts
Export what was found by a firm fieldExportmay openmay openmay openmay opennosrc/app/api/firm/custom-fields/find/route.ts
Export the firm’s administration trailExportyesyesnononosupabase/migrations/20261003230000_unified_member_offboarding.sql
Export one’s own account dataExportown accountown accountown accountown accountown accountsrc/app/api/account/export/route.ts
Verified account deletionBackground jobown accountown accountown accountown accountown accountsupabase/migrations/20261002001000_verified_deletion_reaches_matter_content.sql
Scheduled reports reaching their recipientsBackground jobnames membersnames membersnames membersnames membersnosupabase/migrations/20261003210000_unified_saved_reports.sql
Clio’s signed change noticesBackground jobno personno personno personno personno personsupabase/migrations/20261003200000_unified_clio_billing_events.sql

Data lifecycle

118 stores are removed by a deletion request in their scope, 15 keep a minimized row that names what stays, 58 are retained with a stated reason, and 4 are controlled outside the platform; the full map is in docs/registers/LIFECYCLE-AND-RECOVERY.md. A legal hold beats deletion and is reviewed at least once a year.

Incident process

  1. name the incident owner
  2. stop the exposure (revoke the credential, close the door, pause the lane)
  3. preserve evidence (content-free logs, the release and its provenance)
  4. identify the affected firms and categories from the trace, never from documents
  5. notify the affected firms with the template
  6. remediate and verify with a regression law
  7. close with a written review

Notices are written per firm and never name a document, a client or a matter. The independent assessment will cover:

  • Authentication and session (ASVS V2, V3): the session model, the strict-session flag, the account door closed until SMTP proof.
  • Access control (ASVS V4): the authorize() spine, matter walls, the licence gate, the role table.
  • Input handling and output encoding (ASVS V5): validated inputs on every API route, the nonce CSP, the security headers.
  • Data protection (ASVS V8): field-by-field client and counterparty payloads, the positive visibility policy, content-free logs.
  • Communications and egress (ASVS V9): the egress allow-list and the provider routing rules.
  • Business logic (ASVS V11): the approval semantics, the export gate, the commerce interlock.
  • Files and resources (ASVS V12): upload limits and the scanning posture (M02-05).
  • API and web service (ASVS V13): the scoped API keys and the proposal door (flag-off).

Release discipline

  1. lint
  2. the gate: tsc, the full vitest suite, both-brand builds exit 0, the route and HTML budgets, the UX contracts, the core and keyboard journeys, the accessibility subset and the visual baselines
  3. the secret scan on the staged tree, then an explicit-path commit
  4. push main and wait for the push run found by the full SHA
  5. dispatch the validation run on main (never while a push run is queued)
  6. promote the validated SHA to dc-release and watch the release run
  7. the live checks on both brands: the deployment id, the health probe and the phase pages
  8. the record: the promotion paragraph, the evidence entries, the deployment evidence and the registers regenerated from the committed tree
  9. the Linux visual re-bless when pixels changed on purpose, landed by an explicit cherry-pick of the snapshots only
  10. the release provenance record for the promoted SHA

Support boundaries

  • The platform is drafting and review software for licensed attorneys and their supervised staff; it is not a law firm and gives no legal advice.
  • Support covers the platform's behaviour, its records and its receipts; it never reads client documents to diagnose a failure (the trace is content-free).
  • Owner acts (keys, migrations, flags, rotations, certifications) are listed in the hygiene ledger and the release records, never performed silently.

Owner hygiene

11 open, 1 closed with evidence, 2 accepted in writing; every open item is the owner's act. The ledger is docs/registers/HYGIENE-LEDGER.md.

Exhibits

  • The refusals catalogue: 285 refusals, each with an enforcing symbol and a negative test (src/lib/refusals/catalogue.ts, published at /refusals).
  • The claims registry: 12 registered claims, each with its evidence (src/lib/claims-registry.ts).
  • The data processing agreement template: docs/procurement/DPA-TEMPLATE.md (a draft for counsel to review; signing it is the owner's act).