Documentation ¶
Index ¶
- Variables
- func AesDecrypt(crypted, key []byte) ([]byte, error)
- func AesEncrypt(origData, key []byte) ([]byte, error)
- func Crypto(data []byte, secKey []byte) ([]byte, error)
- func GenerateKeyPair() (pubkey, privkey []byte)
- func PKCS5Padding(ciphertext []byte, blockSize int) []byte
- func PKCS5UnPadding(origData []byte) []byte
- func PubKey(priv []byte) ([]byte, error)
- func RecoverPubKey(msg, sign []byte) ([]byte, error)
- func S256() *secp256k1.BitCurve
- func Sha3_256(data []byte) []byte
- func Validate(data, hash []byte) error
- func Verify(sign, pubKey, msg []byte) bool
Constants ¶
This section is empty.
Variables ¶
View Source
var TestPubKey = []byte("0419e18e6ba7feb6e76fbd933030a20dfe59a24e04ec51133ef5b6825d0457524f1044f00826cc01bbfa981f50e6cbe16446a0760b3d872d716a51e409d8a5deb7")
View Source
var TestSecKey = []byte("ebd71b84d374f881e5280b708c502b2e69de22578d2b1c0fd4dcccd29ad7f4f3")
Functions ¶
func AesDecrypt ¶
func AesEncrypt ¶
func GenerateKeyPair ¶
func GenerateKeyPair() (pubkey, privkey []byte)
func PKCS5Padding ¶
func PKCS5UnPadding ¶
func RecoverPubKey ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.