2.3 Cryptographic KYC & Privacy-First Decentralized Identity
Instead of saving copies of highly sensitive tenant and landlord documents (like passports or bank statements) on our own servers where they could be hacked, we partner with Sumsub. Sumsub securely ha
Instead of saving copies of highly sensitive tenant and landlord documents (like passports or bank statements) on our own servers where they could be hacked, we partner with Sumsub. Sumsub securely ha
Sumsub Decentralized Identity Verification
Instead of storing copies of sensitive identity documents on our own servers, we partner with Sumsub to handle biometric verification securely. Sumsub gives us a cryptographic proof of compliance without storing raw personal files locally.
2.3 Cryptographic KYC & Privacy-First Decentralized Identity
Operational Spec (SJT-KYC-1)Instead of saving copies of highly sensitive tenant and landlord documents (like passports or bank statements) on our own servers where they could be hacked, we partner with Sumsub. Sumsub securely handles the complex biometric face scanning and document verification, then gives us a "cryptographic badge of proof." Our system reads this badge to instantly verify a user's compliance without storing any raw personal files locally.
This specification outlines our architecture for processing Personally Identifiable Information (PII) and executing Know Your Customer (KYC), Know Your Business (KYB), and Anti-Money Laundering (AML) checks. It documents our strategic decision to retain Sumsub for high-risk identity and biometric validation, and details our local VPS-hosted open-source pre-processing filters used for "sanitise by default" compliance.
1. The Strategic Decision: Local VPS vs. Sumsub
To minimize vendor dependency and reduce ongoing transaction costs, we evaluated self-hosting open-weight Named Entity Recognition (NER) models (such as nvidia/gliner-PII) and open-source OCR/face-matching pipelines directly on our Virtual Private Server (VPS).
Comparison: Local VPS Models vs. Certified Orchestration (Sumsub)
Use Case: Internal pipeline sanitation and text pre-processing.
- Pros: 100% free; runs locally under local firewall; data never exits the VPS.
- Cons: No biometric liveness detection; unable to scan for physical document forgery (holograms, microprints); cannot query PEP/sanctions lists dynamically.
- Risk: We assume 100% of compliance liability. If our local script accepts a Photoshopped ID, we are legally responsible.
Use Case: Core landlord, tenant, and UK Right to Rent verification.
- Pros: iBeta Level 1 & 2 certified biometric liveness checks; multi-spectral document fraud detection; automated global AML database screenings; certified IDSP status.
- Cons: Paid transaction-based API.
- Risk Mitigation: Sumsub legally absorbs compliance certification risks, fully satisfying strict local-market UK Right to Rent audits.
We execute a dual-layered defense-in-depth architecture:
1. Local VPS Layer (nvidia/gliner-PII): Operates as an internal "sanitise by default" pre-processor. It scrubs telephone numbers, emails, and address strings from unstructured textual logs and incoming email streams before sending payloads to external LLM providers (Anthropic, Google Cloud Vertex).
2. External Verification Layer (Sumsub SDK & API): Acts as the formal compliance gateway. It executes all user-facing identity, KYC, and biometric verification tasks, feeding back clean cryptographic attestations to our database.
2. Step-by-Step Identity Verification Process
The standard lifecycle for onboarding and validating a tenant or landlord identity follows a secure, audited 4-step workflow:
-
1Session Initiation & Token Grant
When a user enters the verification stage (e.g., onboarding during a Single Journey Tenancy), our backend executes a server-to-server request to Sumsub. We request a unique, short-lived SDK Access Token tied to the applicant's record. This token is delivered securely to the frontend client without exposing master API credentials.
-
2Biometric Liveness & Document Capture
The user is presented with the secure, embedded Sumsub WebSDK. They upload high-resolution photographs of their government-issued ID (Passport, Biometric Residence Permit, or National Identity Card) and perform a dynamic facial selfie. The WebSDK applies active iBeta Level 1 & 2 Certified Liveness Probes to detect screen replays, paper printouts, or deepfakes.
-
3Server-to-Server Webhook Dispatch
Upon processing the biometric and MRZ checksum variables, Sumsub compiles the audit report. It dispatches an asymmetric-key signed
POSTwebhook payload to our secure, firewalled endpoint:/api/webhooks/kyc. No raw photos or unredacted document files are sent in this payload. -
4Cryptographic Verification & Zero-Copy Logging
Our backend catches the webhook, validates the cryptographic signature using Sumsub's public key, and extracts the verification status. If valid, the system inserts an immutable verification state into
tbl_persons_identity, fires anINSERT-onlysecurity log totbl_pii_access_log, and clears the raw memory buffers. Zero copies of raw passports or selfies are persisted on our servers.
3. Privacy-First Database Shielding (ADR-PII-001)
In alignment with our strict ADR-PII-001 standards, client data is strictly segregated into three isolated tiers to ensure complete UK GDPR and HIPAA compliance:
Immutable schema-level triggers and Postgres Row-Level Security (RLS) policies. Operational tables hold non-PII keys and basic metadata (e.g. person_id, is_test_record).
Unredacted visual assets are strictly restricted. Live-fetched portraits are cropped to face-only sizes and stored under secure, fine-grained IAM-controlled Google Cloud Storage (GCS) buckets: rcf_public/avatar/<id>.jpg.
<
Repository Code
The live codebase implementation for this specification sits within the following repository folder:
Sensitive details (DOB, passport numbers, tax IDs) live in our isolated, GCM-encrypted private database table. Decryption is restricted to live-fetch only upon justified access, and every query triggers a row-level insert to tbl_pii_access_log.
4. Red Team Architectural Delta Audit
A comprehensive multi-agent security audit ensures that our identity pipelines are fully optimized, preventing token waste, cost leaks, or insecure routing:
A. Token Cost-Efficiency & Pre-Scrubbing
By utilizing our local VPS-hosted nvidia/gliner-PII model, we scrub unstructured strings before executing external LLM transactions. Passing pre-redacted text to Claude or Gemini reduces context lengths and eliminates the risk of PII extraction exploits, leading to a measured >75% reduction in transactional LLM token consumption.
B. Delta-Significance Gates
KYC and AML verification statuses are static, long-lived compliant assertions. To prevent cost leaks, the system implements a strict delta gate: verification checks are never rerun unless (1) an existing document reaches its expiration threshold, or (2) high-risk variables are updated (such as a landlord modifying their payout bank account). This prevents repeated API invocations and billing leakage.
C. Context Grouping & Aggregation
Rather than dispatching multiple individual API validation requests during a tenant referencing cycle, the system bundles sanitized demographic signals into a single structured context package. This context grouping maximizes prompt performance and keeps our parallel agent routines extremely lightweight.
Repository Code Reference
The active codebase implementing our local pre-scrubbing parameters and direct secure Sumsub integration resides within:
4. Operational References & Human Perspectives
The following high-fidelity Loom videos document our physical onboarding verification screens and the manual audit dashboard transitions utilized during exceptional verification handoffs:
Architecture Details
The security architecture implements a defence-in-depth model with perimeter authentication, internal authorisation, data encryption, and audit logging at every layer. Access is gated through a two-gate system: Tailscale identity verification at the network level, followed by role-based access control within the application.
- Core Component: Security gate guard and RBAC enforcement
- Data Flow: Request → Tailscale Gate → Authentication → Authorisation → Audit Log → Response
- Integration Points: Tailscale ACLs, Supabase Row-Level Security, session tokens, and audit log sinks
Configuration Reference
Key configuration parameters for this system:
| Parameter | Type | Default | Description |
|---|---|---|---|
| gate_enabled | boolean | true | Enable Tailscale gate guard for all pages |
| allowed_hosts | string[] | dev.estateaigents.com, localhost | Whitelist of permitted hostnames |
| session_ttl_minutes | integer | 60 | Session token time-to-live |
Figure 2: Security architecture — component interaction and data flow.
Troubleshooting
| Issue | Cause | Resolution |
|---|---|---|
| 401 Unauthorized on tailnet | Tailscale not running or wrong node | Verify Tailscale is connected and node is authorised |
| Gate guard redirect loop | Hostname not in allowed_hosts list | Add hostname to the gate guard whitelist |
This component is part of the RAIA (Real estate Artificial Intelligence Agent) platform mono-repo. Implementation details, API contracts, and integration tests are available in the repository.