Creating a CAP File in a Java Card Project

To create deliverables in a Java Card project, you must create and configure CAP files.

To create a CAP file:
  1. Select a Java Card Project, click the File menu, and select New and Other….
  2. In the Other… dialog, expand Oracle Java Card SDK and select the Java Card CAP File.
  3. In the Select CAP file type page, select either Compact CAP file or Extended CAP file. Each type of the CAP file has a specific function in the Java Card specification. It is important to note the following:
    • A compact CAP file can have only one Java Card package configured.
    • An extended CAP file can be used only with the 3.1.0 or greater Java Card platform versions.
  4. In the Select CAP file settings page, configure the converter tool options for the build:
    1. In the CAP File AID section, enter a unique CAP file name and CAP file AID. If the CAP file is a compact CAP file, then the AID field is disabled. This is because, the CAP file AID is inherited from the Java Card package that is configured.
    2. In the Converter section, configure the converter tool:
      • In the Options section, enter values for the CAP file version, target platform, and all the flags. If a CAP file is a compact CAP file, then the version is inherited from the Java Card package that is configured. If a CAP file is an extended CAP file, then the target platform must be 3.1.0 or greater and the mask flag option is disabled.
      • In the Export Path section, add the directories in which the converter tool searches for the export files. The verifier tool uses the paths added in this step during the build process. If the paths are added from the project, relative paths are generated.
      • In the CAP Signing section, configure the CAP sign feature of the converter tool.

      Note:

      It is important to note that passwords are stored in plain text in the metadata of your workspace. They are readable by anyone with direct access to this computer.
  5. Click Finish.

    A dialog appears prompting you to confirm if the Java Card package needs to be configured for the CAP file you just created. If you click Yes, the Package Configuration dialog appears. If you click No, the wizard closes and a new configuration file to be included in the build is created.

Managing CAP File Configurations

To manage the CAP file configurations list and to edit a CAP file's configuration, use the CAP file project settings:

  1. Right-click on the Java Card project and select the Java Card and CAP Files Settings.
  2. In the Java Card CAP Files page, to manage the CAP files used in the build, use the following options:
    1. Click Add to create a new CAP file using the wizard.
    2. Click Edit to edit a CAP file's configuration using the wizard with all fields set to the previous values.
    3. Click Delete to delete a CAP file's configuration from the build.