Versions in this module Expand all Collapse all v1 v1.3.4 Dec 14, 2022 v1.3.3 May 11, 2022 Changes in this version + const BlockSize + var ErrDecryption = errors.New("go-pkcs12: decryption error, incorrect padding") + var ErrIncorrectPassword = errors.New("go-pkcs12: decryption password incorrect") + func Decode(pfxData []byte, password string) (privateKey interface{}, certificate *x509.Certificate, err error) + func DecodeAll(pfxData []byte, password string) (privateKey interface{}, certificate []*x.Certificate, err error) + func Encode(privateKey interface{}, certificate *x.Certificate, ...) (pfxData []byte, err error) + func MarshalECPrivateKey(key *sm2.PrivateKey) ([]byte, error) + func MarshalPrivateKey(key *sm2.PrivateKey, oid asn1.ObjectIdentifier) ([]byte, error) + func New(key []byte, t1 int) (cipher.Block, error) + func ParsePKCS8PrivateKey(der []byte) (key interface{}, err error) + func SM2P12Decrypt(fileName string, pwd string) (*x.Certificate, *sm2.PrivateKey, error) + func SM2P12Encrypt(certificate *x.Certificate, pwd string, priv *sm2.PrivateKey, fileName string) error + func ToPEM(pfxData []byte, password string) ([]*pem.Block, error) + type NotImplementedError string + func (e NotImplementedError) Error() string