Redaction class

The secret redactor: one static surface over every redaction rule.

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

redactForDisplay(String name, Object? value) → Object?
Render a name=value pair for a representation, redacting secret-named fields.
redactMapping(Map<String, String>? headers) → Map<String, String>
Redact a flat mapping such as request or response headers.
redactText(String value) → String
Redact every URL and every schemeless path?query inside free text.
redactValue(Object? value) → Object?
A redacted copy of a JSON-shaped value: secret-named entries become redacted, and any other opaque object becomes a type label, never rendered.
shouldRedact(String key) → bool
Whether a key's name means its value must not be shown.
withheldStructure(String text) → String
A value that opens like a structured document and is not one, rendered as its type and size and none of its text: <unparsed String(1234 chars)>.

Constants

circular → const String
What replaces a container that contains itself.
maxDepth → const int
How deep redactValue walks before writing tooDeep.
redacted → const String
What a redacted value is replaced with.
sensitiveKeyMarkers → const List<String>
Key-name markers, matched case-insensitively and ignoring separators.
tooDeep → const String
What replaces a structure nested deeper than maxDepth.
unredactable → const String
What replaces a JSON document the redactor could not finish; fails closed.