redact

package module
v0.0.0-...-6e07223 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2014 License: MIT Imports: 3 Imported by: 0

README

redact

Build Status Test Coverage

redact is a Go package which allows you to easily redact sensitive flag values to prevent them from being exposed as expvars or via debugging endpoints.

For documentation, check godoc.

Documentation

Overview

Package redact provides functionality to redact potentially sensitive flags, to prevent their contents from being exposed via expvars or debugging endpoints.

Example
flag.Parse()                           // parse the args to get the values
RedactFlags(flag.CommandLine, os.Args) // redact them from the runtime

Index

Examples

Constants

This section is empty.

Variables

This section is empty.

Functions

func RedactFlags

func RedactFlags(set *flag.FlagSet, args []string)

RedactFlags iterates through the given FlagSet and arguments slice, and for each non-bool flag which has the string "[SENSITIVE]" in its usage, redacts the value of the flag from the given arguments.

Types

This section is empty.

Jump to

Keyboard shortcuts

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