Documentation
¶
Index ¶
- Constants
- func GetPassword(prompt string, passwordFile string) ([]byte, error)
- func GetPasswordWithConfirmation(passwordFile string) ([]byte, error)
- func ReadKeyfile(path string) ([]byte, error)
- func ReadPassword(prompt string) ([]byte, error)
- func ReadPasswordFile(path string) ([]byte, error)
- func ReadPasswordWithConfirmation() ([]byte, error)
- func SecureZero(data []byte)
Constants ¶
View Source
const ( PasswordEnvVar = "SUPACK_PASSWORD" MinPasswordLength = 8 RecommendedPasswordLength = 12 )
Variables ¶
This section is empty.
Functions ¶
func GetPassword ¶
GetPassword gets password from env var, file, or prompts interactively (no confirmation)
func GetPasswordWithConfirmation ¶
GetPasswordWithConfirmation gets password from env var, file, or prompts with confirmation
func ReadKeyfile ¶
ReadKeyfile reads a keyfile and returns its contents
func ReadPassword ¶
ReadPassword reads a password from stdin without echoing Returns []byte that can be securely zeroed after use
func ReadPasswordFile ¶
ReadPasswordFile reads password from a file
func ReadPasswordWithConfirmation ¶
ReadPasswordWithConfirmation reads a password and asks for confirmation
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.