util

package
v0.0.0-...-cc150fd Latest Latest
Warning

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

Go to latest
Published: May 30, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BcryptHash

func BcryptHash(password string) (string, error)

func BcryptVerify

func BcryptVerify(password, hash string) bool

func DecodeBase64

func DecodeBase64(b64s string) (string, error)

func DecodeBase64ToBytes

func DecodeBase64ToBytes(b64s string) ([]byte, error)

func Decrypt

func Decrypt(key, b64s string) (string, error)

func Deserialize

func Deserialize(byt []byte, ptr interface{}) (err error)

Deserialize deserialices the passed []byte into a the passed ptr interface{}

func EncodeBase64

func EncodeBase64(text string) string

func EncodeBytesToBase64

func EncodeBytesToBase64(b []byte) string

func Encrypt

func Encrypt(key, text string) (string, error)

func EncryptBytes

func EncryptBytes(key, text []byte) (string, error)

func GenerateId

func GenerateId() string

func Serialize

func Serialize(value interface{}) ([]byte, error)

Serialize returns a []byte representing the passed value

Types

This section is empty.

Jump to

Keyboard shortcuts

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