Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RegisterDynamic ¶ added in v0.33.0
func RegisterDynamic(rules ...DynamicRule) error
RegisterDynamic registers exact-value rules on the package-level redactor (the shared pipeline agents and the relay router consume). See (*Redactor).RegisterDynamic for semantics.
func UnregisterDynamic ¶ added in v0.33.0
func UnregisterDynamic(id string)
UnregisterDynamic removes a rule group from the package-level redactor.
Types ¶
type DynamicRule ¶ added in v0.33.0
DynamicRule is an exact-value redaction rule. Unlike the static regex pipeline, the Value is matched literally (no regex metacharacter interpretation) and byte-exactly, so arbitrary key material — including non-UTF-8 bytes — can be registered as a rule. Rules are grouped by ID: RegisterDynamic replaces any existing group with the same ID, and UnregisterDynamic removes the whole group.
Consumers with exact secret material (e.g. the relay-staging provider, which is the one place the platform legitimately knows a staged key's plaintext at seal/resolve time) register rules at the moment the material is known and unregister on revocation.
type Redactor ¶
type Redactor struct {
// contains filtered or unexported fields
}
func NewRedactor ¶
func NewRedactorFromFile ¶
func (*Redactor) DynamicRules ¶ added in v0.34.2
func (r *Redactor) DynamicRules() []DynamicRule
DynamicRules snapshots the registered dynamic rules (dynamic longest-first order). The BYO resolve router (US-72.2) uses it to apply the precise exact-value staged-key rules to proxied bodies — bodies get dynamic-only redaction (the static heuristics would corrupt legitimate structured/vision payloads, e.g. long base64 image parts); diagnostics and logs get the full pipeline via Redact (design 0058 §4.9, K7).
func (*Redactor) RedactDynamicOnly ¶ added in v0.34.2
RedactDynamicOnly applies exactly the dynamic exact-value rules (no static pipeline) — see DynamicRules for why the router's body path uses this surface.
func (*Redactor) RegisterDynamic ¶ added in v0.33.0
func (r *Redactor) RegisterDynamic(rules ...DynamicRule) error
RegisterDynamic adds exact-value rules, grouped by ID. Registering with an ID that already exists atomically replaces that ID's rules — rotation and re-registration are idempotent. Validation failures apply no partial state.
func (*Redactor) UnregisterDynamic ¶ added in v0.33.0
UnregisterDynamic removes every rule in the named group. Unknown IDs are a no-op.