AI Identity
Forensics Pipeline — Technical Architecture
Live Audit Chain
🔍
When would I use this?
Use this pipeline to investigate:

Unauthorized data access by an AI agent
Mis-approved financial actions taken autonomously
Anomalous tool calls outside an agent's declared policy

Every decision is cryptographically recorded — you can reconstruct exactly what happened, when, under which policy, and prove the record was not altered after the fact.
From Request to Evidence (Gateway → Audit Chain)
Every agent request flows through the gateway and becomes a cryptographically chained, tamper-evident evidence record. Click any stage to see what data is captured at that point in the pipeline.
🤖
AI Agent
SDK / API client
click to inspect
🔀
Gateway
:8002
click to inspect
⚖️
Policy Engine
ALLOW / DENY
click to inspect
🌐
Upstream API
e.g. OpenAI
click to inspect
✍️
Audit Writer
async worker
click to inspect
🗄️
PostgreSQL
append-only + RLS
click to inspect
🔐
HMAC Chains ×2
platform + per-org
click to inspect
🚫
Decision
DENY / ERROR
click to inspect
🪪
Mandate Service
signed spend limits
click to inspect

ℹ️ Select a stage above to inspect its data

agent_id
endpoint
method
decision
entry_hash
prev_hash
latency_ms
cost_estimate_usd
Three Layers of Integrity (Write → Export → Anchor)
Each layer answers a different question with a different verifier. Layer 1 makes tampering evident to the organization holding the verification key; Layers 2 and 3 make the evidence publicly verifiable — no shared secret, no trust in our infrastructure. This layered evidence model is now part of the OCSF standard (PR #1661, merged into OCSF 1.9) — and it runs in production here today. Click a layer to inspect it.
🔗
Layer 1 — Write-time
dual keyed HMAC chains
every event · verifier: org key-holder
✒️
Layer 2 — Export-time
ECDSA-P256 per event
every export · verifier: anyone (JWKS)
🌲
Layer 3 — Evidence Anchor
signed Merkle checkpoints
every ~15 min · verifier: anyone (JWKS)

ℹ️ Select a layer above to inspect it

write-time: HMAC chains
export-time: per-event signatures
anchor: Merkle inclusion proofs
AuditLog Schema — Evidence Record
Each row is a forensic evidence record used for incident reconstruction and regulatory response. Every field below is captured on every enforcement decision — allow, deny, or error.
Identity
agent_id
uuid · NOT NULL
agt_8f2c1...
user_id
uuid · nullable
usr_3a4d9...
agent_name
text
"billing-agent-v2"
Request
endpoint
text · NOT NULL
"/v1/chat/completions"
method
text
POST
created_at
timestamptz · DEFAULT now()
2026-04-08T14:23:07Z
Decision
decision
enum · NOT NULL
ALLOW
deny_reason
text · nullable
"rate_limit_exceeded"
status_code
int
200 / 403
Performance
latency_ms
int · not null
12
upstream_latency_ms
int · metadata
847
Cost
cost_estimate_usd
numeric(10,6)
0.002340
token_count
int
1847
Chain Integrity
entry_hash
text · NOT NULL
a3f9b2c...
prev_hash
text · nullable
d84e1fa...
entry_hash_org
text · per-org chain
f21c8ad...
prev_hash_org
text · per-org chain
6b90e3c...
org_chain_seq
int · gap-free 1..N per org
1042
Policy
policy_version
int · Policy snapshot ID at decision time
3
deny_rule_id
text · Exact rule that denied access
"rate_limit_exceeded"
Chain Integrity Verification (How Auditors Prove No Tampering)
Each audit entry includes an HMAC-SHA256 hash computed over the full payload plus the previous entry's hash — forming a linked chain. Tampering with any entry breaks all subsequent hashes, and the per-org sequence numbers (org_chain_seq 1..N) make any deleted row show up as a gap. An auditor holding the organization's forensic verification key can independently recompute the chain and confirm it has not been altered; for verification without the key, use the per-event export signatures and Evidence Anchor inclusion proofs from Section 2.
seq 1 GENESIS
prev_hash_org
entry_hash_org
a3f9b2c4d1e8...
seq 2 ALLOW
prev_hash_org
entry_hash_org
d84e1fa7b5c2...
seq 3 DENY
prev_hash_org
entry_hash_org
9e2c6f3a8b41...
seq 4 ALLOW
prev_hash_org
entry_hash_org
c17d4e9f2a5b...
seq 5 ALLOW
prev_hash_org
entry_hash_org
7b3a8f1d9c6e...
📄 Chain-of-Custody Certificate

Every exported Case File (JSON and CSV) includes a chain-of-custody certificate that shows the forensic data came from AI Identity and has not been altered after export. The platform signs a compact summary — report ID, generation timestamp, chain verification status, and entry counts — with the same key the audit chain verified under, producing a report_signature that travels with the export. Any recipient holding the organization's forensic verification key can recompute that summary and verify the signature, confirming both the integrity of the underlying hash chain and the authenticity of the export itself. This certificate is the key-holder layer; for verification without the org key, the OCSF export carries per-event ECDSA-P256 signatures and the Case File bundle carries Evidence Anchor inclusion proofs — both check out against our public JWKS at api.ai-identity.co/.well-known/ai-identity-public-keys.json.

# Verify a forensics report export hasn't been tampered with
import hmac, hashlib, json

def verify_report_signature(
    secret_key: bytes,
    report_id: str,
    generated_at: str,        # ISO 8601 UTC
    chain_valid: bool,
    total_entries: int,
    entries_verified: int,
    signature_hex: str,
) -> bool:
    payload = {
        "entries_verified": entries_verified,
        "chain_valid": chain_valid,
        "generated_at": generated_at,
        "report_id": report_id,
        "total_entries": total_entries,
    }
    msg = json.dumps(payload, sort_keys=True, separators=(",", ":"))
    expected = hmac.new(secret_key, msg.encode(), hashlib.sha256).hexdigest()
    return hmac.compare_digest(expected, signature_hex)
Competitive Comparison — Forensics Capabilities
Most IAM and AI governance tools stop at "logs." AI Identity adds cryptographic identity, tamper-evident chains, and signed chain-of-custody exports — capabilities no competing platform ships today.
Capability AI Identity Opal Valence Cognition
Cryptographic agent identity
Tamper-evident audit chain
Fail-closed proxy gateway
Independent chain verification
Decision replay / audit query ⚠ partial (timeline & policy-aware filters)
Policy snapshot per entry
Signed export certificate
Publicly verifiable evidence (per-event signatures + Merkle inclusion proofs)
Signed spend-limit mandates for agent commerce
See it live in under 5 minutes
Sign up, register an agent, and watch every decision appear in your tamper-evident audit trail — free tier included.
1
Sign Up
Create your account and get your organization API key — no credit card required.
2
Register an Agent
Create an agent identity and point your AI traffic through the gateway proxy.
3
See Your Audit Trail
Every decision is cryptographically chained. Verify, export, and prove what happened.