Versions in this module Expand all Collapse all v0 v0.0.1 Sep 18, 2019 Changes in this version + const COMPEVENFLAG + const COMPODDFLAG + const COMPRESSEDLEN + const FLAGLEN + const INFINITYLEN + const NOCOMPRESSEDFLAG + const NOCOMPRESSEDLEN + const P256PARAMA + const P256R1 + const SM2 + const XORYVALUELEN + var AlgChoice int + func AesDecrypt(ciphertext []byte, key []byte, iv []byte) ([]byte, error) + func AesEncrypt(plaintext []byte, key []byte, iv []byte) ([]byte, error) + func ComputeRoot(hashes []Uint256) (Uint256, error) + func DoubleHash(s []Uint256) Uint256 + func Equal(e1 *PubKey, e2 *PubKey) bool + func Md5(str string) []byte + func PKCS5Padding(src []byte, blockSize int) []byte + func PKCS5UnPadding(src []byte) []byte + func SetAlg(algChoice string) + func Sha256(value []byte) []byte + func Sign(privateKey []byte, data []byte) ([]byte, error) + func ToAesKey(pwd []byte) []byte + func Verify(publicKey PubKey, data []byte, signature []byte) error + type MerkleTree struct + Depth uint + Root *MerkleTreeNode + func NewMerkleTree(hashes []Uint256) (*MerkleTree, error) + type MerkleTreeNode struct + Hash Uint256 + Left *MerkleTreeNode + Right *MerkleTreeNode + func (node *MerkleTreeNode) IsLeaf() bool + type PubKey struct + X *big.Int + Y *big.Int + func DecodePoint(encodeData []byte) (*PubKey, error) + func GenKeyPair() ([]byte, PubKey, error) + func NewPubKey(priKey []byte) *PubKey + func (e *PubKey) DeSerialize(r io.Reader) error + func (e *PubKey) EncodePoint(isCommpressed bool) ([]byte, error) + func (e *PubKey) Serialize(w io.Writer) error + type PubKeySlice []*PubKey + func (p PubKeySlice) Len() int + func (p PubKeySlice) Less(i, j int) bool + func (p PubKeySlice) Swap(i, j int)