crypto

package
v1.0.46 Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2023 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateRandomBytes

func GenerateRandomBytes(size int) []byte

GenerateRandomBytes returns random bytes.

func GenerateRandomString

func GenerateRandomString(size int) string

GenerateRandomString returns a random string.

func GenerateRandomStringHex

func GenerateRandomStringHex(size int) string

GenerateRandomStringHex returns a random hexadecimal string.

func Hash

func Hash(value string) string

Hash returns a SHA-256 checksum of a string.

func HashFromBytes

func HashFromBytes(value []byte) string

HashFromBytes returns a SHA-256 checksum of the input.

func HashPassword

func HashPassword(password string) (string, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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