Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // OIDs OIDData = asn1.ObjectIdentifier{1, 2, 840, 113549, 1, 7, 1} OIDEnvelopedData = asn1.ObjectIdentifier{1, 2, 840, 113549, 1, 7, 3} OIDEncryptionAlgorithmRSAESOAEP = asn1.ObjectIdentifier{1, 2, 840, 113549, 1, 1, 7} OIDEncryptionAlgorithmAES256CBC = asn1.ObjectIdentifier{2, 16, 840, 1, 101, 3, 4, 1, 42} // Versions EnvelopedDataVersion = 2 EnvelopedDataRecipientInfoVersion = 2 )
Functions ¶
func DecryptEnvelopedKey ¶
func DecryptEnvelopedKey(key *rsa.PrivateKey, content []byte) ([]byte, error)
Types ¶
type EncryptedKey ¶
type EncryptedKey struct {
// contains filtered or unexported fields
}
func Parse ¶
func Parse(ber []byte) (*EncryptedKey, error)
func (*EncryptedKey) Decrypt ¶
func (ek *EncryptedKey) Decrypt(key *rsa.PrivateKey) ([]byte, error)
Click to show internal directories.
Click to hide internal directories.