redact

package
v0.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 21, 2026 License: Apache-2.0 Imports: 1 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package redact identifies and masks header values that commonly carry credentials, so they never round-trip back out through API responses, `readproof inspect`, or `readproof resource list` — even if an operator pasted a raw secret instead of using the "${VAR}" environment-reference form the http source adapter resolves at fetch time (see internal/source/http).

Index

Constants

View Source
const Placeholder = "[REDACTED]"

Variables

This section is empty.

Functions

func Headers

func Headers(headers map[string]string) map[string]string

Headers returns a copy of headers with sensitive values replaced by Placeholder. Non-sensitive entries pass through unchanged.

func IsSensitiveHeader

func IsSensitiveHeader(name string) bool

IsSensitiveHeader reports whether a header name commonly carries a credential, by exact well-known name or by substring heuristic (e.g. "X-Api-Key", "X-Auth-Token").

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL