redact

package
v1.11.0 Latest Latest
Warning

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

Go to latest
Published: Aug 6, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package redact masks secret material so it never appears in Geiger output.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Line

func Line(s string) string

Line redacts any token-shaped substring inside free text, so accidental echoes of a raw secret in a log line or error message are masked.

func Secret

func Secret(s string) string

Secret masks a credential, preserving only a short tail for correlation. Short secrets are fully masked. Examples:

Secret("ghp_aBcD...wXyZJV3Q") => "ghp_…JV3Q"
Secret("abc")                 => "…"

Types

This section is empty.

Jump to

Keyboard shortcuts

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