public class SubjectKeyIdentifierExtension extends Extension
Extensions are additional attributes which can be inserted in a X509 v3 certificate. For example a "Driving License Certificate" could have the driving license number as an extension.
Extensions are represented as a sequence of the extension identifier (Object Identifier), a boolean flag stating whether the extension is to be treated as being critical and the extension value itself (this is again a DER encoding of the extension value).
Extension| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
NAME |
critical, extensionId, extensionValue| Constructor and Description |
|---|
SubjectKeyIdentifierExtension(java.lang.Boolean critical,
java.lang.Object value)
Create the extension from the passed DER encoded value.
|
SubjectKeyIdentifierExtension(byte[] octetString)
Create a SubjectKeyIdentifierExtension with the passed octet string.
|
| Modifier and Type | Method and Description |
|---|---|
void |
encode(com.tencent.kona.sun.security.util.DerOutputStream out)
Write the extension to the OutputStream.
|
KeyIdentifier |
getKeyIdentifier() |
java.lang.String |
getName()
Return the name of this extension.
|
java.lang.String |
toString()
Returns a printable representation.
|
encode, equals, getExtensionId, getExtensionValue, getId, getValue, hashCode, isCritical, newExtensionpublic static final java.lang.String NAME
public SubjectKeyIdentifierExtension(byte[] octetString)
octetString - the octet string identifying the key identifier.public SubjectKeyIdentifierExtension(java.lang.Boolean critical,
java.lang.Object value)
throws java.io.IOException
critical - true if the extension is to be treated as critical.value - an array of DER encoded bytes of the actual value.java.lang.ClassCastException - if value is not an array of bytesjava.io.IOException - on error.public java.lang.String toString()
public void encode(com.tencent.kona.sun.security.util.DerOutputStream out)
public KeyIdentifier getKeyIdentifier()