toolsdk

package module
v0.0.0-...-e37a865 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2022 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PKCS7Padding

func PKCS7Padding(ciphertext []byte, blockSize int) []byte

func StringPtr

func StringPtr(s string) *string

func ToStr

func ToStr(value interface{}, args ...int) (s string)

Types

type ApiPwdDecryption

type ApiPwdDecryption struct {
	// contains filtered or unexported fields
}

* 密码加/解密算法

func (*ApiPwdDecryption) Decryption

func (me *ApiPwdDecryption) Decryption() *ApiPwdDecryption

func (*ApiPwdDecryption) Encryption

func (me *ApiPwdDecryption) Encryption() *ApiPwdDecryption

func (*ApiPwdDecryption) GetErrMsg

func (me *ApiPwdDecryption) GetErrMsg() string

func (*ApiPwdDecryption) GetPwd

func (me *ApiPwdDecryption) GetPwd() string

func (*ApiPwdDecryption) GetPwdPreFix

func (me *ApiPwdDecryption) GetPwdPreFix() []string

func (*ApiPwdDecryption) GetPwdSign

func (me *ApiPwdDecryption) GetPwdSign() string

func (*ApiPwdDecryption) SetErrMsg

func (me *ApiPwdDecryption) SetErrMsg(errMsg string) *ApiPwdDecryption

func (*ApiPwdDecryption) SetPwd

func (me *ApiPwdDecryption) SetPwd(pwd string) *ApiPwdDecryption

func (*ApiPwdDecryption) SetPwdPreFix

func (me *ApiPwdDecryption) SetPwdPreFix(pwdPreFix []string) *ApiPwdDecryption

func (*ApiPwdDecryption) SetPwdSign

func (me *ApiPwdDecryption) SetPwdSign(pwdSign string) *ApiPwdDecryption

type ApiSign

type ApiSign struct {
	// contains filtered or unexported fields
}

func NewApiSign

func NewApiSign() *ApiSign

func (*ApiSign) AppendData

func (m *ApiSign) AppendData(k string, v interface{}) *ApiSign

func (*ApiSign) GetData

func (m *ApiSign) GetData() map[string]interface{}

func (*ApiSign) GetSecret

func (m *ApiSign) GetSecret() string

func (ApiSign) GetSignString

func (m ApiSign) GetSignString() string

func (*ApiSign) MakeSign

func (m *ApiSign) MakeSign() string

签名

func (*ApiSign) SetData

func (m *ApiSign) SetData(p map[string]interface{}) *ApiSign

func (*ApiSign) SetJsonData

func (m *ApiSign) SetJsonData(str string) *ApiSign

func (*ApiSign) SetSecret

func (m *ApiSign) SetSecret(s string) *ApiSign

type ArgInt

type ArgInt []int

func (ArgInt) Get

func (a ArgInt) Get(i int, args ...int) (r int)

type StrTo

type StrTo string

func (StrTo) Float32

func (f StrTo) Float32() (float32, error)

func (StrTo) Float64

func (f StrTo) Float64() (float64, error)

func (StrTo) Int

func (f StrTo) Int() (int, error)

func (StrTo) Int64

func (f StrTo) Int64() (int64, error)

func (StrTo) IntV0

func (f StrTo) IntV0() (int, error)

func (StrTo) MustFloat32

func (f StrTo) MustFloat32() float32

func (StrTo) MustFloat64

func (f StrTo) MustFloat64() float64

func (StrTo) MustInt

func (f StrTo) MustInt() int

func (StrTo) MustInt64

func (f StrTo) MustInt64() int64

func (StrTo) MustUint64

func (f StrTo) MustUint64() uint64

func (StrTo) MustUint8

func (f StrTo) MustUint8() uint8

func (StrTo) String

func (f StrTo) String() string

func (StrTo) Uint64

func (f StrTo) Uint64() (uint64, error)

func (StrTo) Uint8

func (f StrTo) Uint8() (uint8, error)

type WxCrypt

type WxCrypt struct {
	AppId      string
	SessionKey string
	RespDto    interface{} // 自定义struct,用于接收解密的结果
}

func (*WxCrypt) Decrypt

func (w *WxCrypt) Decrypt(encryptedData string, iv string) error

Decrypt 微信业务数据解密 AES-128-CBC

func (*WxCrypt) PKCS7UnPadding

func (w *WxCrypt) PKCS7UnPadding(src []byte) []byte

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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