argon2id

package module
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2022 License: MIT Imports: 7 Imported by: 0

README

argon2id

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultConfig = &Config{
	Memory:     64 * 1024,
	Time:       1,
	Threads:    2,
	SaltLength: 16,
	KeyLength:  32,
}

Functions

func ComparePasswordHash

func ComparePasswordHash(password, hash string) (match bool, err error)

func CreateNewHash

func CreateNewHash(password string, config *Config) (hash string, err error)

Types

type Config

type Config struct {
	Memory     uint32
	Time       uint32
	Threads    uint8
	SaltLength uint32
	KeyLength  uint32
}

func ParseHash

func ParseHash(hash string) (config *Config, salt, key []byte, err error)

func VerifyHash

func VerifyHash(password, hash string) (match bool, config *Config, err error)

Jump to

Keyboard shortcuts

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