|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.novell.security.japi.pki.NPKIToolbox | +--com.novell.security.japi.pki.NPKITcrl
The NPKITcrl
class provides the Certificate Revocation List functions
that extend the NPKIToolbox
API.
Constructor Summary | |
NPKITcrl()
Provides the default constructor for the CRL. |
Method Summary | |
void |
createContext()
Creates a new NPKIT_CRL context structure and initializes it with default values. |
void |
decode(byte[] crlData,
byte[][] unsignedCRL,
java.lang.Integer sigAlgType,
java.lang.String[] sigAlgOID,
byte[][] signature,
java.lang.Integer version,
java.lang.String[] issuerName,
java.lang.Integer thisUpdateSeconds,
java.lang.Integer nextUpdateSeconds,
java.lang.Integer numRevokedCertificates,
java.lang.Integer numCRLExtensions)
Decodes the specified CRL from its ASN.1 DER encoding. |
void |
entryExtensionInfo(int extensionIndex,
java.lang.Integer x509ExtensionType,
java.lang.String[] oid,
java.lang.Boolean critical,
byte[][] value)
Returns the specified ASN.1 encoded extension for the CRL entry. |
void |
entryInfo(int index,
byte[][] serialNumber,
java.lang.Integer revocationSeconds,
java.lang.Integer extensionNum)
Returns the serial number, length of the serial number, the date and the time the certificate was revoked for the index specified. |
void |
extensionInfo(int index,
java.lang.Integer x509ExtensionType,
java.lang.String[] oid,
java.lang.Boolean critical,
byte[][] value)
Returns information about the specified extension of the CRL (Certificate Revocation List). |
void |
freeContext()
Frees a previously allocated CRL (Certificate Revocation List) context and all associated memory. |
protected void |
initialize()
Initializes the PKI context. |
int |
invalidityDateInfo()
Returns the invalidity date associated with the CRL entry. |
int |
reasonCodeInfo()
Returns the CRL invalidity reason code associated with the CRL entry. |
Methods inherited from class com.novell.security.japi.pki.NPKIToolbox |
decodeCSR, destroy, finalize, getUTCString, loadLibrary, version |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public NPKITcrl() throws NPKI_Exception
NPKI_Exception
- A PKI error codeMethod Detail |
protected void initialize() throws NPKI_Exception
NPKIToolbox
This function must be called to instantiate PKI services.
initialize
in class NPKIToolbox
NPKI_Exception
- Throws a PKI error code if not successful.public void createContext() throws NPKI_Exception
createContext
in class NPKIToolbox
NPKI_Exception
- Throws a PKI error code if not successful.
The initialization includes creating an NWDS context, initializing NW calls, and setting up the Unicode tables.
freeContext
,
decode
public void freeContext() throws NPKI_Exception
freeContext
in class NPKIToolbox
NPKI_Exception
- Throws a PKI error code if not successful.createContext
public void decode(byte[] crlData, byte[][] unsignedCRL, java.lang.Integer sigAlgType, java.lang.String[] sigAlgOID, byte[][] signature, java.lang.Integer version, java.lang.String[] issuerName, java.lang.Integer thisUpdateSeconds, java.lang.Integer nextUpdateSeconds, java.lang.Integer numRevokedCertificates, java.lang.Integer numCRLExtensions) throws NPKI_Exception
crlData
- (IN) CRL to be decoded.unsignedCRL
- (OUT) Returns a byte array of the unsigned portion of the CRL.sigAlgType
- (OUT) Returns an Integer to the algorithm used in the signature.sigAlgOID
- (OUT) A string that has a human-readable form of
the signature algorithm OID (i.e., {1 2 840 113549 1 1 1}).signature
- (OUT) Signature of the CRL.version
- (OUT) Version number of the CRL.issuerName
- (OUT) The name of the CA that issued the CRL.thisUpdateSeconds
- (OUT) Representation of the most recent
date the CRL was updated.
NOTE: The time is in UTC standard time.
nextUpdateSeconds
- (OUT) Representation of the date when the
CRL will be updated next.
NOTE: Represented as the number of seconds since 00:00:00 UTC January 1, 1970.
numRevokedCertificates
- (OUT) Number of revoked certificates in the CRL.numCRLExtensions
- (OUT) Number of extensions associated with the CRL.
NPKI_Exception
- Throws a PKI error code if not successful.createContext
,
freeContext
,
entryInfo
,
extensionInfo
public void entryExtensionInfo(int extensionIndex, java.lang.Integer x509ExtensionType, java.lang.String[] oid, java.lang.Boolean critical, byte[][] value) throws NPKI_Exception
A successful call to decode
followed by a successful call
to entryInfo
must have previously been made. The extension
retrieved in this call is for the entry specified in the successful
call to entryInfo
.
extensionIndex
- (IN) Indicates which extension is to be returned.
NOTE: index is 0 based.
x509ExtensionType
- (OUT) Returns an Integer of the extension type of the extension indicated
by the extensionIndex. See extension types in Subject Alternative Names
Extension.oid
- (OUT) A String representation of the OID (Object Identifier).critical
- (OUT) Returns whether the extension is critical or not.value
- (OUT) Returns a byte array of the ASN.1 encoded value of the extension.
NPKI_Exception
- Throws a PKI error code if not successful.decode
,
entryInfo
,
reasonCodeInfo()
,
invalidityDateInfo
public void entryInfo(int index, byte[][] serialNumber, java.lang.Integer revocationSeconds, java.lang.Integer extensionNum) throws NPKI_Exception
A successful call to decode
must be made prior to making this call.
Subsequent calls to entryExtensionInfo
can be made to
retrieve the CRL entry extension information for each of the CRL
entry extensions identified in numberOfCRLEntryExtensions
.
index
- (IN) Indicates which Certificate Revocation List entry information is to
be returned.
NOTE: Index is 0 based.
serialNumber
- (OUT) Returns a byte array of the serial number of the specified revoked certificate.revocationSeconds
- (OUT) Returns an Integer representation of the time and date the
specified certificate was revoked.
NOTE: Represented as the number of seconds since 00:00:00 UTC January 1, 1970.
extensionNum
- (OUT) Returns the number of extensions of the specified certificate.
NPKI_Exception
- Throws a PKI error code if not successful.decode
,
entryExtensionInfo
,
reasonCodeInfo
,
invalidityDateInfo
public void extensionInfo(int index, java.lang.Integer x509ExtensionType, java.lang.String[] oid, java.lang.Boolean critical, byte[][] value) throws NPKI_Exception
A successful call to decode
must be made prior
to making this call.
index
- (IN) Indicates which Certificate Revocation List extension
is to be returned.
NOTE: Index is 0 based.
x509ExtensionType
- (OUT) Returns an Integer to the extension type.oid
- (OUT) A String representation of the OID (Object Identifier) that
identifies the extension.critical
- (OUT) Returns whether the extension is critical or not.value
- (OUT) Returns a byte array of the ASN.1 encoded value of the extension indicated
by the index.
NPKI_Exception
- Throws a PKI error code if not successful.decode
public int invalidityDateInfo() throws NPKI_Exception
A successful call to decode
followed by a successful call
to entryExtensionInfo
must have previously been made. The
invalidity date retrieved in this call is for the entry specified
in the successful call to entryInfo
.
NOTE: The invalidity date is an optional extension, so not all CRL entrys will have an associated invalidity date.
NOTE: Represented as the number of seconds since 00:00:00 UTC January 1, 1970.
NPKI_Exception
- Throws a PKI error code if not successful.extensionInfo
,
decode
,
entryInfo
public int reasonCodeInfo() throws NPKI_Exception
A successful call to decode
followed by a successful call
to entryInfo
must have previously been made. The reason code
retrieved in this call is for the entry specified in the successful call to
entryInfo
.
NPKI_Exception
- Throws a PKI error code if not successful.decode
,
entryInfo
,
entryExtensionInfo
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |