password

package module
v0.3.4 Latest Latest
Warning

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

Go to latest
Published: Jan 5, 2022 License: MIT Imports: 19 Imported by: 1

README

Usage

Generate random string

Usage: password [option...]

Options:
  -digits int
        Number of digits to include in the password (default 4)
  -length int
        Specify the password length (default 16)
  -lower int
        Number of lowercase letters to include in the password (default 4)
  -symbol int
        Number of symbols to include in the password (default 2)
  -upper int
        Number of uppsercase letters to include in the password (default 2)

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Digits6 [2]int = [2]int{6, 1000000}
	Digits8 [2]int = [2]int{8, 100000000}

	Digits = Digits6

	OTP otp
)
View Source
var Cost int = 15
View Source
var Encrypt encrypt
View Source
var Hash hashs

Functions

func GenAll

func GenAll(length uint) string

func GenLower

func GenLower(length uint) string

func GenNumber

func GenNumber(length uint) string

func GenQRCode added in v0.3.1

func GenQRCode(content string, size int)

func GenSymbol

func GenSymbol(length uint) string

func GenUpper

func GenUpper(length uint) string

func GeneratePassword

func GeneratePassword(length, minLower, minUpper, minSymbol, minNumber uint) string

func NewOTP added in v0.3.1

func NewOTP(account, issuer string) (string, error)

func ReadQRCode added in v0.3.1

func ReadQRCode(filename string) string

Types

type Decrypt

type Decrypt struct {
	// contains filtered or unexported fields
}

func (*Decrypt) Compare

func (d *Decrypt) Compare(p string) bool

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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