Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultFilterLevel = Moderate
DefaultFilterLevel is used by Filter() when no level is specified.
Functions ¶
func FilterWithLevel ¶ added in v0.5.0
func FilterWithLevel(content string, level FilterLevel) string
FilterWithLevel replaces secrets in content with [REDACTED] at the specified level.
func IsLikelySecret ¶
IsLikelySecret heuristically determines if a token string is a secret.
Types ¶
type FilterLevel ¶ added in v0.5.0
type FilterLevel int
FilterLevel controls how aggressively content is filtered.
const ( // Strict strips everything (emails, IPs, phones, secrets). Strict FilterLevel = iota // Moderate keeps infrastructure IPs (10.x, 192.168.x) and work-related emails. Moderate // Minimal only strips high-entropy secrets and explicit API keys. Minimal )
Click to show internal directories.
Click to hide internal directories.