mp_hash

package
v0.0.0-...-5b025be Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2023 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Base64Decode

func Base64Decode(str string) string

Base64Decode Base64解码 OK

func Base64Encode

func Base64Encode(str string) string

Base64Encode Base64转码 OK

func CertFormat

func CertFormat(key string, isPub bool) (cert string, err error)

CertFormat 格式化证书

func DeStr

func DeStr(pass string, key string) string

DeStr 解密可解密字符串 OK

func EnStr

func EnStr(pass string, key string) string

EnStr 生成可解密字符串 OK

func GetExpireTime

func GetExpireTime(sec int) string

GetExpireTime 获取过期N秒的时间 OK

func GetSn

func GetSn() string

GetSn 获取随机sn OK

func GetTime10

func GetTime10() string

GetTime10 获取当前时间戳(10位) OK

func GetTime10Int

func GetTime10Int() int

GetTime10Int 获取当前时间戳(10位) OK

func GetTime13

func GetTime13() string

GetTime13 获取当前时间戳(13位) OK

func GetTime13Int

func GetTime13Int() int64

GetTime13Int 获取当前时间戳(13位) OK

func GzipCompress

func GzipCompress(s string) (r string, err error)

GzipCompress GZIP压缩字符串 OK

func GzipCompressByte

func GzipCompressByte(b []byte) (r string, err error)

GzipCompressByte GZIP压缩字符串 OK

func GzipUnCompress

func GzipUnCompress(s string) (result []byte, err error)

GzipUnCompress GZIP解压缩字符串 OK

func GzipUnCompressByte

func GzipUnCompressByte(s []byte) (result []byte, err error)

GzipUnCompressByte GZIP解压缩字符串 OK

func Md5Byte

func Md5Byte(b []byte) (m []byte)

Md5Byte 生成MD5Byte OK

func Md5Lower

func Md5Lower(str string) string

Md5Lower 返回小写md5字符串 OK

func Md5Upper

func Md5Upper(str string) string

Md5Upper 返回大写md5字符串 OK

func MdDecode

func MdDecode(str string, key string, expSec int) string

MdDecode 梦蝶跨平台解密算法,expSec密钥有效期(秒) OK

func MdEncode

func MdEncode(str string, key string, expSec int) string

MdEncode 梦蝶跨平台加密算法,expSec密钥过期时间(秒) OK

func MdXor

func MdXor(str, key string) string

MdXor 异或az算法 OK

func MtRand

func MtRand(min, max int) int

MtRand 生成区间范围的随机整数 OK

func RandStr

func RandStr(k string, n int) string

RandStr 生成指定长度和类型(数字/字母/特殊字符)的随机字符串 OK

func Rsa2Private

func Rsa2Private(str string, key string, encode bool) (rs string, e error)

Rsa2Private RSA2私钥加解密 OK

func Rsa2Public

func Rsa2Public(str string, key string, encode bool) (rs string, e error)

Rsa2Public RSA2公钥加解密 OK

Types

This section is empty.

Jump to

Keyboard shortcuts

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