Class PKCS12KeyInfo


  • public class PKCS12KeyInfo
    extends java.lang.Object
    This object is used for carrying key info around. It does not handle raw key material (but it used to). FIXME: A clear refactoring opportunity exists. The 'privateKey' field (and associated constructor) is only used during export, and the 'epkiBytes' field (and associated constructor) is only used during import. Therefore this should be two different types.
    • Constructor Detail

      • PKCS12KeyInfo

        public PKCS12KeyInfo()
      • PKCS12KeyInfo

        public PKCS12KeyInfo​(org.mozilla.jss.crypto.PrivateKey k)
        Construct with a PrivateKey. This constructor is used for moving the PrivateKey handle around during export.
      • PKCS12KeyInfo

        public PKCS12KeyInfo​(byte[] epkiBytes)
        Construct with a (serialised) EncrypedPrivateKeyInfo. This constructor is used for moving the EPKI data around during import.
    • Method Detail

      • getPrivateKey

        public org.mozilla.jss.crypto.PrivateKey getPrivateKey()
      • getEncryptedPrivateKeyInfoBytes

        public byte[] getEncryptedPrivateKeyInfoBytes()
      • getID

        public byte[] getID()
      • setID

        public void setID​(byte[] id)
      • getFriendlyName

        public java.lang.String getFriendlyName()
      • setFriendlyName

        public void setFriendlyName​(java.lang.String friendlyName)