EncryptedPrivateKeyInfo.fromAsn1 constructor
EncryptedPrivateKeyInfo.fromAsn1(
- ASN1Sequence sequence
EncryptedPrivateKeyInfo ::= SEQUENCE { encryptionAlgorithm AlgorithmIdentifier, encryptedData OCTET STRING }
Implementation
factory EncryptedPrivateKeyInfo.fromAsn1(ASN1Sequence sequence) {
final algorithm =
AlgorithmIdentifier.fromAsn1(sequence.elements[0] as ASN1Sequence);
return EncryptedPrivateKeyInfo(
algorithm, (sequence.elements[1] as ASN1OctetString).contentBytes()!);
}