Cloakwall: Stdlib-Only PII Redaction With Tamper-Evident Audit Logs for LLM Traffic

OldBodybuilder7090 · reddit · 2026-10-31

Cloakwall v0.1.1 is a pure-stdlib Python tool, running as a LiteLLM guardrail, that redacts PII (emails, cards, SSNs, IBANs, API keys, NHS/medical numbers, phones, IPs, DOBs) from LLM requests and responses — covering chat, system prompts, tool-call arguments, Anthropic tool blocks, Responses API, embeddings and image prompts. Streamed output passes a hold-back buffer to catch entities split across chunks. Every redaction goes to a SHA-256 hash-chained audit log with anchor files; tampering is detectable and no redacted values are stored. 0.05ms per clean request, 1.8ms with PII plus fsynced audit entry. Trades Presidio's NLP recall for zero dependencies and offline use; LLM Guard's repo was archived July 2026. Aimed at healthcare, fintech and air-gapped teams; 76 tests, CI on 3.10–3.13, not yet production-proven.

Original post →

More from coding & agent

coding & agent channel →