Versions in this module Expand all Collapse all v0 v0.0.1 Oct 21, 2022 Changes in this version + func New(keyStore bccsp.KeyStore, curve *math.Curve, translator idemix.Translator, ...) (*csp, error) + type CSP struct + Decryptors map[reflect.Type]Decryptor + Encryptors map[reflect.Type]Encryptor + Hashers map[reflect.Type]Hasher + KeyDerivers map[reflect.Type]KeyDeriver + KeyGenerators map[reflect.Type]KeyGenerator + KeyImporters map[reflect.Type]KeyImporter + Signers map[reflect.Type]Signer + Verifiers map[reflect.Type]Verifier + func NewImpl(keyStore bccsp.KeyStore) (*CSP, error) + func (csp *CSP) AddWrapper(t reflect.Type, w interface{}) error + func (csp *CSP) Decrypt(k bccsp.Key, ciphertext []byte, opts bccsp.DecrypterOpts) (plaintext []byte, err error) + func (csp *CSP) Encrypt(k bccsp.Key, plaintext []byte, opts bccsp.EncrypterOpts) ([]byte, error) + func (csp *CSP) GetHash(opts bccsp.HashOpts) (h hash.Hash, err error) + func (csp *CSP) GetKey(ski []byte) (k bccsp.Key, err error) + func (csp *CSP) Hash(msg []byte, opts bccsp.HashOpts) (digest []byte, err error) + func (csp *CSP) KeyDeriv(k bccsp.Key, opts bccsp.KeyDerivOpts) (dk bccsp.Key, err error) + func (csp *CSP) KeyGen(opts bccsp.KeyGenOpts) (k bccsp.Key, err error) + func (csp *CSP) KeyImport(raw interface{}, opts bccsp.KeyImportOpts) (k bccsp.Key, err error) + func (csp *CSP) Sign(k bccsp.Key, digest []byte, opts bccsp.SignerOpts) (signature []byte, err error) + func (csp *CSP) Verify(k bccsp.Key, signature, digest []byte, opts bccsp.SignerOpts) (valid bool, err error) + type Decryptor interface + Decrypt func(k bccsp.Key, ciphertext []byte, opts bccsp.DecrypterOpts) (plaintext []byte, err error) + type Encryptor interface + Encrypt func(k bccsp.Key, plaintext []byte, opts bccsp.EncrypterOpts) (ciphertext []byte, err error) + type Hasher interface + GetHash func(opts bccsp.HashOpts) (h hash.Hash, err error) + Hash func(msg []byte, opts bccsp.HashOpts) (hash []byte, err error) + type KeyDeriver interface + KeyDeriv func(k bccsp.Key, opts bccsp.KeyDerivOpts) (dk bccsp.Key, err error) + type KeyGenerator interface + KeyGen func(opts bccsp.KeyGenOpts) (k bccsp.Key, err error) + type KeyImporter interface + KeyImport func(raw interface{}, opts bccsp.KeyImportOpts) (k bccsp.Key, err error) + type Signer interface + Sign func(k bccsp.Key, digest []byte, opts bccsp.SignerOpts) (signature []byte, err error) + type Verifier interface + Verify func(k bccsp.Key, signature, digest []byte, opts bccsp.SignerOpts) (valid bool, err error)