Function scrub_credentials_value
pub fn scrub_credentials_value(value: Value) -> ValueExpand description
Structured-aware credential scrub for a JSON value bound for a human-facing
surface. Object entries whose key names a credential have their entire value
replaced with a marker, preserving the key. Every other string leaf still
runs through the text scrub_credentials so inline token=... patterns
inside unrelated fields are caught too. Serialize-then-scrub would corrupt
key names that merely contain a sensitive word (e.g. access_token), so this
walks the value instead. Same rendering-boundary contract as
scrub_credentials.