Documentation
¶
Overview ¶
Package secrets finds credentials in text. It is shared by the repo file scanner and the scanner that checks records before they are written.
Index ¶
Constants ¶
const ( MinEntropy = 3.5 MinLength = 20 )
The entropy rule for a value assigned to a credential-named variable.
Variables ¶
This section is empty.
Functions ¶
func HighEntropy ¶
HighEntropy applies the rule for a value with no known prefix.
func LooksLikeSecret ¶
LooksLikeSecret is the record scanner's test for one value.
Types ¶
type Classes ¶
Classes decide what environment a file belongs to.
func DefaultClasses ¶
func DefaultClasses() Classes
DefaultClasses are the built-in rules. Config can add to them.
type Finding ¶
type Finding struct {
Kind string
Line int
Value string
KeyID string // AWS access key ID, an identifier and never the secret
}
Finding is one credential in a file. Value is held in memory only, to be hashed, and must never be stored.