Oracle Security Developer Tools Security Engine Java API Reference
10g (10.1.4.0.1)

B28175-01


oracle.security.crypto.cert.ext
Class NameConstraintsExtension

java.lang.Object
  extended byoracle.security.crypto.cert.X509Extension
      extended byoracle.security.crypto.cert.ext.NameConstraintsExtension

All Implemented Interfaces:
oracle.security.crypto.asn1.ASN1Object, oracle.security.crypto.util.Streamable

public class NameConstraintsExtension
extends X509Extension

Represents the certificate extension Name Constraints from RFC 2459. This extension must be critical in CA certificates.

Note that this implementation always sets the minimum subtree base distance to 0 (the default) and always omits the maximum.


Field Summary

 

Fields inherited from class oracle.security.crypto.cert.X509Extension
id_netscape_ce, id_netscape_ce_type, id_set_ce, id_set_ce_type, isDecoded

 

Constructor Summary
NameConstraintsExtension()
          Create a new extension with the appropriate OID type.
NameConstraintsExtension(java.io.InputStream is)
           
NameConstraintsExtension(java.util.Vector permitted, java.util.Vector excluded)
          Creates a new extension with the given permitted and/or excluded subtree lists.
NameConstraintsExtension(java.util.Vector permitted, java.util.Vector excluded, boolean critical)
          Creates a new extension with the given permitted and/or excluded subtree lists and critical flag.

 

Method Summary
 void addExcludedSubtree(GeneralName name)
           
 void addPermittedSubtree(GeneralName name)
           
 java.util.Vector getExcludedSubtrees()
          Gets the excluded subtrees defined for this extension.
 java.util.Vector getPermittedSubtrees()
          Gets the permitted subtrees defined for this extension.
 java.lang.String toString()
          Returns a string representation of this object.

 

Methods inherited from class oracle.security.crypto.cert.X509Extension
getASN1Value, getCritical, getID, getType, getValue, input, input, inputInstance, isRecognized, length, output, setCritical, setValue

 

Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

 

Constructor Detail

NameConstraintsExtension

public NameConstraintsExtension()
Create a new extension with the appropriate OID type.

Note: An object created using this constructor may not be in a valid state. This constructor is intended primarily for use in conjunction with the X509Extension.input(java.io.InputStream) method.


NameConstraintsExtension

public NameConstraintsExtension(java.util.Vector permitted,
                                java.util.Vector excluded)
Creates a new extension with the given permitted and/or excluded subtree lists. The extension is critical.
Parameters:
permitted - A Vector of GeneralNames which are the permitted subtrees for this Name Constraints extension (may be null).
excluded - A Vector of GeneralNames which are the excluded subtrees for this Name Constraints extension (may be null).

NameConstraintsExtension

public NameConstraintsExtension(java.util.Vector permitted,
                                java.util.Vector excluded,
                                boolean critical)
Creates a new extension with the given permitted and/or excluded subtree lists and critical flag.
Parameters:
permitted - A Vector of GeneralNames which are the permitted subtrees for this Name Constraints extension (may be null).
excluded - A Vector of GeneralNames which are the excluded subtrees for this Name Constraints extension (may be null).
critical - true if this extension is critical, false otherwise.

NameConstraintsExtension

public NameConstraintsExtension(java.io.InputStream is)
                         throws java.io.IOException

Method Detail

getPermittedSubtrees

public java.util.Vector getPermittedSubtrees()
Gets the permitted subtrees defined for this extension.
Returns:
A Vector of GeneralNames, or null if none are defined.

getExcludedSubtrees

public java.util.Vector getExcludedSubtrees()
Gets the excluded subtrees defined for this extension.
Returns:
A Vector of GeneralNames, or null if none are defined.

addPermittedSubtree

public void addPermittedSubtree(GeneralName name)

addExcludedSubtree

public void addExcludedSubtree(GeneralName name)

toString

public java.lang.String toString()
Description copied from class: X509Extension
Returns a string representation of this object.
Overrides:
toString in class X509Extension
Returns:
a string representation

Oracle Security Developer Tools Security Engine Java API Reference
10g (10.1.4.0.1)

B28175-01


Copyright © 2005 ,2006 , Oracle. All rights reserved.