public class PKCS12KeyBag extends PKCS12Bag
Constructor and Description |
---|
PKCS12KeyBag()
Creates a new empty instance.
|
PKCS12KeyBag(PKCS12Safe parent) |
PKCS12KeyBag(PKCS12Safe parent,
ASN1Sequence s) |
PKCS12KeyBag(PKCS12Safe parent,
PrivateKey key) |
Modifier and Type | Method and Description |
---|---|
PrivateKey |
getPrivateKey() |
ASN1Sequence |
getPrivateKeyInfo() |
void |
input(ASN1Sequence s)
Reconstructs this object from its representation as an ASN.1 sequence.
|
void |
input(java.io.InputStream is)
Reconstructs this object by reading its DER encoding from the
specified input stream.
|
int |
length()
Returns the length of this object's DER encoding.
|
void |
output(java.io.OutputStream os)
Outputs the DER encoding of this object to the specified output stream.
|
void |
setPrivateKey(PrivateKey key) |
java.lang.String |
toString()
Returns a string representation of this object.
|
getFriendlyName, getLocalKeyID, inputBag, outputAttrsASN1, readExternal, setFriendlyName, setLocalKeyID, writeExternal
public PKCS12KeyBag()
public PKCS12KeyBag(PKCS12Safe parent)
public PKCS12KeyBag(PKCS12Safe parent, PrivateKey key)
public PKCS12KeyBag(PKCS12Safe parent, ASN1Sequence s) throws java.io.IOException
java.io.IOException
public void input(java.io.InputStream is) throws java.io.IOException
is
- the input stream from which this object will be readjava.io.IOException
public void input(ASN1Sequence s) throws java.io.IOException
s
- the ASN.1 sequence representation of this objectjava.io.IOException
public void output(java.io.OutputStream os) throws java.io.IOException
os
- the output stream to which the object will be writtenjava.io.IOException
public int length()
public PrivateKey getPrivateKey()
public ASN1Sequence getPrivateKeyInfo()
public void setPrivateKey(PrivateKey key)
public java.lang.String toString()
toString
in class java.lang.Object