redact

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2026 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Overview

Package redact masks secret-shaped values in free text before it crosses a trust boundary — specifically before tool output (pod/controller logs, git diffs, status/event messages) is fed to the LLM provider, from where the model's quoted evidence would otherwise flow on into a (possibly public) KB pull request and chat. It is deliberately HIGH-PRECISION: it targets clearly secret-shaped tokens and sensitive key=value pairs, masking the *value* while preserving surrounding structure (the key name, the diff line) so the investigation can still reason ("the password field changed") without the secret leaving the boundary. It is not a guarantee — redaction is a mitigation, not a substitute for not logging secrets.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Secrets

func Secrets(s string) string

Secrets masks secret-shaped substrings in s, returning the redacted text. It is safe to call on already-redacted text (idempotent).

Types

This section is empty.

Jump to

Keyboard shortcuts

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