Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CalcMd5File ¶
TODO(@benqi): remove to baselib
func GenerateNonce ¶
func GenerateStringNonce ¶
func Sha1Digest ¶
func Sha256Digest ¶
Types ¶
type AES256IGECryptor ¶
type AES256IGECryptor struct {
// contains filtered or unexported fields
}
func NewAES256IGECryptor ¶
func NewAES256IGECryptor(aesKey, aesIV []byte) *AES256IGECryptor
type AesCTR128Encrypt ¶
type AesCTR128Encrypt struct {
// contains filtered or unexported fields
}
func NewAesCTR128Encrypt ¶
func NewAesCTR128Encrypt(key []byte, iv []byte) (*AesCTR128Encrypt, error)
key长度必须为16、24或32
func (*AesCTR128Encrypt) Encrypt ¶
func (this *AesCTR128Encrypt) Encrypt(plaintext []byte) []byte
type AesCTR128KeySizeError ¶
type AesCTR128KeySizeError int
func (AesCTR128KeySizeError) Error ¶
func (k AesCTR128KeySizeError) Error() string
type RSACryptor ¶
type RSACryptor struct {
// contains filtered or unexported fields
}
bca2c43964f3b7d1e7dfff4a769fd174770487399df315de2d2a47208cda5d32c90f0f01849cb58d1fe2a9e1bc25ee72aed55a6ea312900ea5b48a60ca51fffff1688ccb17d411eee043d8397420074a8e8ba92bd3c8976481fdfe238f40e583b0bf8bb7c8031b4c41cbeb0f7bfd991ddcca3235fa3bd078b0eb318c5ae4e6a0e8583ae2a09a2b009ede1407cfa4e05fdb0ef7a215ee752ac913495b43ca4258da4c63c701f62f2bf96062b5cbe8b8b0c0be6b674d7eda921a03ce62a0a49058962018e2a03bdefeeee5421ea44f10815d2308e8712423ee6cff1d83efcf94b2d52b2c54e4276242d663d84332e2cf7194d2b35fc5decc4d0c1c46ba6d0a6717
func (*RSACryptor) Decrypt ¶
func (m *RSACryptor) Decrypt(b []byte) []byte
func (*RSACryptor) Encrypt ¶
func (m *RSACryptor) Encrypt(b []byte) []byte
Click to show internal directories.
Click to hide internal directories.