Previous Topic

Next Topic

Book Contents

Generating a Java Keystore and Public/Private Key Pair

Before you use the P6 Web Services encryption and digital signatures features you need to generate a public/private key pair.

To generate a Java keystore and public/private key pair

First, make sure that you are using the supported JDK version for this release. Next, ensure that the bin folder of the JDK is set to your system path. Then perform the following steps:

  1. Open a command prompt and issue the following command:

    keytool -validity 3600 -genkey -keyalg RSA -alias mykeys -keystore keystore.jks

    If necessary, modify the preceding command for your environment.

  2. Enter the appropriate information as prompted by the system prompts. For example:


    keystore password: demo123
    first and last name: demo user
    oraganizational unit: demo org
    organization: demo
    city: demo city
    state: demo state
    country code: us
    type yes when prompted if the information is correct.
    press enter when prompted to enter a key password (do not enter anything)

    Note: The proceeding responses are for example purposes only. Substitute the appropriate responses for your environment.

  3. After performing the steps above your keystore will be generated in the location specified in step 1. The keystore contains the private key that will be used by P6 Web Services and the public key that will be used by the client. The P6 Web Services demo application is an example of a client that can be set up to use a public key

    Note: Typically you will need to export the the certificate containing the public key from the keystore and import that public key into a keystore accessible by the client. For the sake of clarity, this procedure documents how to use the same keystore for both the client and P6 Web Services.

  4. Copy the keystore to a location that is accessible by P6 Web Services and the P6 Web Services client application. The P6 Web Services Demo program is a client application. If P6 Web Services is on a different machine than P6 Professional, copy the keystore to both machines.

Related Topics

Introduction

Architecture

Standards

About P6 Web Services

Using P6 Web Services

Demonstration Applications

Configure P6 Web Services to Use Username Token with Encryption and Digital Signatures

Run P6 Web Services Demo

Using the Client Stub Classes

Handling the Apache CXF Java Client Timeout


Copyright information