Graphorin API reference v0.7.0
Graphorin API reference / @graphorin/observability / redaction/patterns / RedactionPattern
Interface: RedactionPattern
Defined in: packages/observability/src/redaction/patterns.ts:58
One entry in the redaction catalogue.
Stable
Properties
| Property | Modifier | Type | Description | Defined in |
|---|---|---|---|---|
category | readonly | PatternCategory | - | packages/observability/src/redaction/patterns.ts:60 |
description | readonly | string | - | packages/observability/src/redaction/patterns.ts:61 |
mask? | readonly | string | Replacement string used when mode === 'mask'. | packages/observability/src/redaction/patterns.ts:64 |
name | readonly | string | - | packages/observability/src/redaction/patterns.ts:59 |
optIn? | readonly | boolean | Optional opt-in flag. When true the pattern is not active by default; operators must add it to enabledPatterns explicitly. Used by the IPv4 / IPv6 patterns because raw IPs frequently appear in non-PII log lines (host headers, debug traces, …). | packages/observability/src/redaction/patterns.ts:79 |
regex | readonly | RegExp | - | packages/observability/src/redaction/patterns.ts:62 |
verify? | readonly | (match) => boolean | Optional per-match predicate (RP-21). When present, a regex hit is only treated as a real match - and masked - when this returns true for the matched substring. Used by the creditcard pattern to require a valid Luhn checksum so look-alike digit runs (epoch-ms timestamps, order ids) are not corrupted. | packages/observability/src/redaction/patterns.ts:72 |