seclib2

package
v2.2.2+incompatible Latest Latest
Warning

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

Go to latest
Published: Sep 30, 2018 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DIGITS  = "23456789"
	LETTERS = "abcdefghjkmnpqrstuvwxyz"
	UPPERS  = "ABCDEFGHJKMNPRSTUVWXYZ"
	PUNC    = "()~@#$%^&*-+={}[]:;<>,.?/"

	ALL_DIGITS  = "0123456789"
	ALL_LETTERS = "abcdefghijklmnopqrstuvwxyz"
	ALL_UPPERS  = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
	ALL_PUNC    = "~`!@#$%^&*()-_=+[]{}|:';\",./<>?"
)

Variables

View Source
var CHARS = fmt.Sprintf("%s%s%s%s", DIGITS, LETTERS, UPPERS, PUNC)

Functions

func MeetComplxity

func MeetComplxity(passwd string) bool

func RandomPassword2

func RandomPassword2(width int) string

Types

type PasswordStrength

type PasswordStrength struct {
	Digits     int
	Lowercases int
	Uppercases int
	Punctuats  int
}

func AnalyzePasswordStrenth

func AnalyzePasswordStrenth(passwd string) PasswordStrength

func (PasswordStrength) Len

func (ps PasswordStrength) Len() int

func (PasswordStrength) MeetComplexity

func (ps PasswordStrength) MeetComplexity() bool

Jump to

Keyboard shortcuts

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