Class PrivateKeyInfo

  • All Implemented Interfaces:
    ASN1Encodable, Encodable

    public class PrivateKeyInfo
    extends ASN1Object
    RFC 5958
      [IMPLICIT TAGS]
    
      OneAsymmetricKey ::= SEQUENCE {
          version                   Version,
          privateKeyAlgorithm       PrivateKeyAlgorithmIdentifier,
          privateKey                PrivateKey,
          attributes            [0] Attributes OPTIONAL,
          ...,
          [[2: publicKey        [1] PublicKey OPTIONAL ]],
          ...
      }
    
      PrivateKeyInfo ::= OneAsymmetricKey
    
      Version ::= INTEGER { v1(0), v2(1) } (v1, ..., v2)
    
      PrivateKeyAlgorithmIdentifier ::= AlgorithmIdentifier
                                         { PUBLIC-KEY,
                                           { PrivateKeyAlgorithms } }
    
      PrivateKey ::= OCTET STRING
                         -- Content varies based on type of key.  The
                         -- algorithm identifier dictates the format of
                         -- the key.
    
      PublicKey ::= BIT STRING
                         -- Content varies based on type of key.  The
                         -- algorithm identifier dictates the format of
                         -- the key.
    
      Attributes ::= SET OF Attribute { { OneAsymmetricKeyAttributes } }