password

package module
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Aug 1, 2020 License: MIT Imports: 4 Imported by: 0

README

go-pass

golang password encoder and verifier

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrPasswordIncorrect indicates password is incorrect
	ErrPasswordIncorrect = errors.New("password incorrect")
	// ErrHashInvalid indicates hash is invalid
	ErrHashInvalid = errors.New("invalid hash")
)

Functions

func NewUUID

func NewUUID() string

NewUUID generates a new v4 UUID

Types

type Hash

type Hash struct{}

Hash service

func (*Hash) Compare

func (c *Hash) Compare(hash string, s string) error

Compare string to generated hash

func (*Hash) Generate

func (c *Hash) Generate(s string) (string, error)

Generate a salted hash for the input string

Jump to

Keyboard shortcuts

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