crypto

package
v0.0.0-...-74262d2 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2022 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertToByte

func ConvertToByte(password string) []byte

ConvertToByte converts a string to a byte

func GenerateHashedPassowrd

func GenerateHashedPassowrd(password string) (hashed string, err error)

GenerateHashedPassowrd generates a bcrypt password that is hashed, if there is no error, it converts the byte to a string, and returns a nil error otherwiser it return and empty sting and the error

func VerifyPassword

func VerifyPassword(hahsed string, password string) bool

VerifyPassword takes the hashed password and plain password submitte and verifys them. Returns true if they match, or false if not

Types

This section is empty.

Jump to

Keyboard shortcuts

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