utils

package
v1.0.0-alpha.10 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BytesReverse

func BytesReverse(s []byte) []byte

BytesReverse ... 将 byte 内容反转

func DateRange

func DateRange(start, end time.Time, f func(time.Time) error) error

func DayInMonth

func DayInMonth(year, month int) (days int)

func GenerateSN

func GenerateSN() string

GenerateSN generate sn

func Getenv

func Getenv(key string) string

Getenv ... 环境变量值获取

func GetenvDef

func GetenvDef(key, def string) string

GetenvDef ... 环境变量值获取 若无有效值,则使用提供的默认值

func MD5

func MD5(src []byte) string

MD5 md5 hash

func PasswordHash

func PasswordHash(password string) (string, error)

PasswordHash make password hash

func PasswordVerify

func PasswordVerify(password, hash []byte) error

PasswordVerify password validation

func SHA256

func SHA256(src []byte) string

SHA256 sha256 hash

Types

This section is empty.

Jump to

Keyboard shortcuts

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