6 Oracle PKI SDK

There are a number of packages for PKI, LDAP, and timestamp functions in Oracle PKI SDK, which is a set of software development kits (SDKs) for developing PKI-aware applications.

A public key infrastructure (PKI) is a security architecture that provides an increased level of confidence when exchanging information over the Internet.

We explain PKI features and the various sub-packages of Oracle PKI:

6.1 Oracle PKI CMP SDK

This section provides information about using the Oracle public key infrastructure (PKI) Software Development Kit (SDK) for certificate management protocol (CMP). Oracle PKI CMP SDK allows Java developers to quickly implement certificate management functionality such as issuing and renewing certificates, creating and publishing CRLs, and providing key recovery capabilities.

6.1.1 Oracle PKI CMP SDK Features and Benefits

The Oracle PKI CMP SDK provides the following features and functionality:

  • Oracle PKI CMP SDK conforms to RFC 2510, and is compatible with other products that conform to this certificate management protocol (CMP) specification. RFC 2510 defines protocol messages for all aspects of certificate creation and management.

  • Oracle PKI CMP SDK conforms to RFC 2511, and is compatible with other products that conform to this certificate request message format (CRMF) specification. RFC 2511 describes the Certificate Request Message Format (CRMF), which is used to convey X.509 certificate requests to a Certification Authority (CA).

The Oracle PKI CMP SDK toolkit contains the following packages:

  • The oracle.security.crypto.cmp package provides classes that implement certificate management protocol (CMP) as described in RFC 2510, and certificate request message format (CRMF) as described in RFC 2511.

  • The oracle.security.crypto.cmp.attribute package provides attribute classes for registration controls, registration information, and general information. This package includes the following classes and their subclasses:

    • RegistrationControl

    • RegistrationInfo

    • InfoTypeAndValue (which extends oracle.security.crypto.cert.AttributeTypeAndValue)

  • The oracle.security.crypto.cmp.transport package provides classes for CMP and CRMF transport protocols. It includes the TCPMessage class and its specific message-type subclasses.

6.1.2 Setting Up Your Oracle PKI CMP SDK Environment

The Oracle Security Developer Tools are installed with Oracle WebLogic Server in ORACLE_HOME.

In order to use Oracle PKI CMP SDK, your system must have the Java Development Kit (JDK) version 1.6 or higher.

Your CLASSPATH environment variable must contain the full path and file names to all of the required jar and class files. Make sure the following items are included in your CLASSPATH:

  • osdt_core.jar

  • osdt_cert.jar

  • osdt_cms.jar

  • osdt_cmp.jar

For example, your classpath may look like:

%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_core.jar;
%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_cert.jar;
%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_cms.jar;
%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_cmp.jar

6.1.3 The Oracle PKI CMP SDK Java API Reference

The Oracle PKI CMP SDK Java API reference (Javadoc) is available at:

Oracle Fusion Middleware Java API Reference for Oracle Security Developer Tools

6.2 Oracle PKI OCSP SDK

This section provides information about using the Oracle Online Certificate Status Protocol (OCSP) Software Development Kit (SDK). Oracle PKI OCSP SDK allows Java developers to quickly develop OCSP-enabled client applications and OCSP responders that conform to RFC 2560 specifications.

This section contains the following topics:

6.2.1 Oracle PKI OCSP SDK Features and Benefits

Oracle PKI OCSP SDK provides the following features and functionality:

  • Oracle PKI OCSP SDK conforms to RFC 2560 and is compatible with other products that conform to this specification, such as Valicert's Validation Authority. RFC 2560 specifies a protocol useful in determining the current status of a digital certificate without requiring CRLs.

  • The Oracle PKI OCSP SDK API provides classes and methods for constructing OCSP request messages that can be sent through HTTP to any RFC 2560 compliant validation authority.

  • The Oracle PKI OCSP SDK API provides classes and methods for constructing responses to OCSP request messages, and an OCSP server implementation that you can use as a basis for developing your own OCSP server to check the validity of certificates you have issued.

6.2.2 Setting Up Your Oracle PKI OCSP SDK Environment

The Oracle Security Developer Tools are installed with Oracle WebLogic Server in ORACLE_HOME.

In order to use Oracle PKI OCSP SDK, your system must have the Java Development Kit (JDK) version 1.6 or higher. Also, make sure that your PATH environment variable includes the Java bin directory.

Your CLASSPATH environment variable must contain the full path and file names to all of the required jar and class files. Make sure the following items are included in your CLASSPATH:

  • osdt_core.jar

  • osdt_cert.jar

  • osdt_ocsp.jar

For example:

setenv CLASSPATH $CLASSPATH:$ORACLE_HOME/modules/oracle.osdt_11.1.1/osdt_core.jar:
$ORACLE_HOMEmodules/oracle.osdt_11.1.1/osdt_cert.jar:
$ORACLE_HOMEmodules/oracle.osdt_11.1.1/osdt_ocsp.jar

6.2.3 The Oracle PKI OCSP SDK Java API Reference

The Oracle PKI OCSP SDK Java API reference (Javadoc) is available at:

Oracle Fusion Middleware Java API Reference for Oracle Security Developer Tools

6.3 Oracle PKI TSP SDK

This section provides information about using the Oracle PKI TSP SDK, which allows Java developers to quickly implement time-stamping functionality within a public key infrastructure (PKI) framework.

This section contains the following topics:

6.3.1 Oracle PKI TSP SDK Features and Benefits

Oracle PKI TSP SDK provides the following features and functionality:

  • Oracle PKI TSP SDK conforms to RFC 3161 and is compatible with other products that conform to this time stamp protocol (TSP) specification.

  • Oracle PKI TSP SDK provides an example implementation of a TSA server to use for testing TSP request messages, or as a basis for developing your own time stamping service.

Oracle PKI TSP SDK contains the following classes and interfaces:

Table 6-1 Oracle PKI TSP SDK Classes and Interfaces

Class or Interface Name Description

TSP Interface

Defines various constants associated with the Time Stamp Protocol (TSP).

HttpTSPRequest Class

Implementation of a TSP request message over HTTP.

HttpTSPResponse Class

Implementation of a TSP response message over HTTP.

MessageImprint Class

This class represents a MessageImprint object as defined in RFC 3161.

TSAPolicyID Class

This class represents a TSAPolicyID object as defined in RFC 3161.

TSPContentHandlerFactory Class

A content handler for TSP over HTTP.

TSPMessage Class

A TSP message.

TSPTimeStampReq Class

A TSP message of type TimeStampReq as defined in RFC 3161.

TSPTimeStampResp Class

A TSP message of type TimeStampResp as defined in RFC 3161.

TSPUtils Class

Defines various utility methods for the oracle.security.crypto.tsp package.

6.3.2 Setting Up Your Oracle PKI TSP SDK Environment

The Oracle Security Developer Tools are installed with Oracle WebLogic Server in ORACLE_HOME.

In order to use Oracle PKI TSP SDK, your system must have the Java Development Kit (JDK) version 1.6 or higher. Also, make sure that your PATH environment variable includes the Java bin directory.

Your CLASSPATH environment variable must contain the full path and file names to all of the required jar and class files. Make sure the following items are included in your CLASSPATH:

  • osdt_core.jar

  • osdt_cert.jar

  • osdt_cms.jar

  • osdt_cmp.jar

  • osdt_tsp.jar

For example:

setenv CLASSPATH $CLASSPATH:$ORACLE_HOME/modules/oracle.osdt_11.1.1/osdt_core.jar:
$ORACLE_HOME/modules/oracle.osdt_11.1.1/osdt_cert.jar:
$ORACLE_HOME/modules/oracle.osdt_11.1.1/osdt_cms.jar:
$ORACLE_HOME/modules/oracle.osdt_11.1.1/osdt_cmp.jar;
$ORACLE_HOME/modules/oracle.osdt_11.1.1/osdt_tsp.jar

6.3.3 The Oracle PKI TSP SDK Java API Reference

The Oracle PKI TSP SDK Java API reference (Javadoc) is available at:

Oracle Fusion Middleware Java API Reference for Oracle Security Developer Tools

6.4 Oracle PKI LDAP SDK

This section provides information about using Oracle PKI LDAP SDK, which allows Java developers to quickly implement operations that involve publishing and retrieving digital certificates from a directory server.

This section contains the following topics:

6.4.1 Oracle PKI LDAP SDK Features and Benefits

Oracle PKI LDAP SDK provides facilities for accessing a digital certificate within an LDAP directory. Some of the tasks you can perform with Oracle PKI LDAP SDK are:

  • Validating a user's certificate in an LDAP directory

  • Adding a certificate to an LDAP directory

  • Retrieving a certificate from an LDAP directory

  • Deleting a certificate from an LDAP directory

The oracle.security.crypto.LDAP package contains two classes:

  • LDAPCertificateValidator, which validates a user certificate by checking whether it exists in its subject's LDAP directory entry

  • LDAPUtils, which is a collection of methods to add, retrieve, and remove certificates from a subject's LDAP directory entry

6.4.2 Setting Up Your Oracle PKI LDAP SDK Environment

The Oracle Security Developer Tools are installed with Oracle WebLogic Server in ORACLE_HOME.

To use Oracle PKI LDAP SDK, your system must have the following:

  • Java Development Kit (JDK) version 1.6 or higher. Also, make sure that the Java bin directory is added to your PATH environment variable.

  • Oracle's Java Naming and Directory Interface (JNDI) version 1.2.1 or higher. You must add all of the JNDI jar files to your CLASSPATH.

Your CLASSPATH environment variable must contain the full path and file names to all of the required jar and class files. Make sure the following items are included in your CLASSPATH:

  • osdt_core.jar

  • osdt_cert.jar

  • osdt_ldap.jar

  • jndi.jar, ldapbp.jar, ldap.jar, jaas.jar, and providerutil.jar (Oracle's Java Naming and Directory Interface (JNDI))

For example:

%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_core.jar;
%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_cert.jar;
%ORACLE_HOME%\modules\oracle.osdt_11.1.1\osdt_ldap.jar;

6.4.3 The Oracle PKI LDAP SDK Java API Reference

The Oracle PKI LDAP SDK Java API reference (Javadoc) is available at:

Oracle Fusion Middleware Java API Reference for Oracle Security Developer Tools