onepassword

package
v0.0.0-...-3f0be0e Latest Latest
Warning

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

Go to latest
Published: Nov 7, 2021 License: MIT Imports: 9 Imported by: 0

README

This is the library definition of go-one-password.

See the build instructions and the command line interface and graphical user interface versions to see how it can be used in password generating applications.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	IS_ALPHANUMERIC = regexp.MustCompile("[A-Za-z0-9]+")
	HAS_UPPERCASE   = regexp.MustCompile("[A-Z]{1,5}")
	HAS_LOWERCASE   = regexp.MustCompile("[a-z]{1,5}")
	HAS_NUMERICS    = regexp.MustCompile("[0-9]{1,5}")
)

Functions

func GetCandidatePwd

func GetCandidatePwd(pp, usr, host string, g, i int) string

GetCandidatePwd computes a password string based on the passphrase, hostname, username, a generation number, and an iteration number

func PwdIsValid

func PwdIsValid(pwd string, pwdLen int) bool

PwdIsValid checks the string created by getCandidatePwd and returns a boolean depending on whether or not it meets the criteria: the first pwdLen characters are all alphanumeric, and there is at least one (but no more than 5) uppercase, lowercase and numeric characters

Types

This section is empty.

Jump to

Keyboard shortcuts

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