public class InhibitAnyPolicyExtension extends Extension
The inhibit any-policy extension can be used in certificates issued to CAs. The inhibit any-policy indicates that the special any-policy OID, with the value {2 5 29 32 0}, is not considered an explicit match for other certificate policies. The value indicates the number of additional certificates that may appear in the path before any- policy is no longer permitted. For example, a value of one indicates that any-policy may be processed in certificates issued by the sub- ject of this certificate, but not in additional certificates in the path.
This extension MUST be critical.
The ASN.1 syntax for this extension is:
id-ce-inhibitAnyPolicy OBJECT IDENTIFIER ::= { id-ce 54 }
InhibitAnyPolicy ::= SkipCerts
SkipCerts ::= INTEGER (0..MAX)
Extension| Modifier and Type | Field and Description |
|---|---|
static com.tencent.kona.sun.security.util.ObjectIdentifier |
AnyPolicy_Id
Object identifier for "any-policy"
|
static java.lang.String |
NAME |
critical, extensionId, extensionValue| Constructor and Description |
|---|
InhibitAnyPolicyExtension(java.lang.Boolean critical,
java.lang.Object value)
Create the extension from the passed DER encoded value of the same.
|
InhibitAnyPolicyExtension(int skipCerts)
Default constructor for this object.
|
| Modifier and Type | Method and Description |
|---|---|
void |
encode(com.tencent.kona.sun.security.util.DerOutputStream out)
Encode this extension value to the output stream.
|
java.lang.String |
getName()
Return the name of this extension.
|
int |
getSkipCerts() |
java.lang.String |
toString()
Return user readable form of extension.
|
encode, equals, getExtensionId, getExtensionValue, getId, getValue, hashCode, isCritical, newExtensionpublic static com.tencent.kona.sun.security.util.ObjectIdentifier AnyPolicy_Id
public static final java.lang.String NAME
public InhibitAnyPolicyExtension(int skipCerts)
skipCerts - specifies the depth of the certification path.
Use value of -1 to request unlimited depth.public InhibitAnyPolicyExtension(java.lang.Boolean critical,
java.lang.Object value)
throws java.io.IOException
critical - criticality flag to use. Must be true for this
extension.value - a byte array holding the DER-encoded extension value.java.lang.ClassCastException - if value is not an array of bytesjava.io.IOException - on error.