feat(core): redaction policy, Redacted<T>, and no-secrets-in-logs canary #378

Merged
KofTwentyTwo merged 1 commits from story/obs-7-redaction-canary into dev 2026-08-01 01:07:03 +00:00
1 Commits
Author SHA1 Message Date
James Maes 656ffe868e feat(core): redaction policy, Redacted<T>, and no-secrets-in-logs canary
Add a Redacted<T> newtype in nuncio-core whose Debug, Display, and serde
render a fixed placeholder, so a wrapped credential cannot leak through a
derived Debug or serde_json; the value is reachable only via an explicit
expose_secret(). Migrate the CalDAV/CardDAV account auth tokens to it and
drop their hand-written redacting Debug impls.

Document the logging redaction policy (what must never be logged vs what
is allowed) in docs/LOGGING.md and the redact module doc.

Add a cross-crate no-secrets canary that installs a capturing subscriber,
drives auth reject, account add, mock and JMAP-wiremock sync, mark-read,
send, a filter rule-fire, a webhook dispatch, and CalDAV/CardDAV sync with
sentinel secrets/PII, and asserts none appear in captured telemetry.

Refs #363
2026-07-31 20:04:14 -05:00