Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8248481

Smartcardio implementation does not support the logical channel opening as declared by JCRE/ISO 7816-4

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P3 P3
    • None
    • None
    • security-libs
    • None

      According to section 4.5 of Java Card Platform Runtime Environment 3.1 specification and section 5.5.2 of the ISO 7816-4:2013 Specification there are two ways to open logical channel:

      1. By selecting an applet instance on a new logical channel. This is accomplished by issuing an Applet SELECT FILE APDU command, and specifying the logical channel number in the CLA byte of the command. If this logical channel is currently closed, it shall be opened, and the specified applet instance shall be selected. See Section 4.6.2 Applet Selection with SELECT FILE.

      2. By issuing a MANAGE CHANNEL OPEN APDU command. MANAGE CHANNEL commands are provided to open a logical channel from another logical channel, or to close a logical channel from another logical channel. See Section 4.5.1 MANAGE CHANNEL Command Processing.

      Oracle's smartcatdio implementation does not support both of them.

      Select file apdu commands are redirected to current logical channel in the sun.security.smartcardio.ChannelImpl and new channel is not opened.

      Manage CHANNEL CHANNEL apdu commands are ignored by sun.security.smartcardio.ChannelImpl and IllegalArgumentException is thrown with diagnostic "Manage channel command not allowed, use openLogicalChannel()"

      Since channels is an integral part of smartcard specifications, to fully use jcre we must include your own smartcardio api implementation into the products that is not correct. For example, our simulator uses own smartcardio implementation to support channels and pass the certification. It overloads the product. Other example is JavaCard TCK. It can not use own GP service as is because some tests checks the channels in the way that is not supported by Oracle's smartcardio implementation. Licensee requires to patch jdk to use our service.

      So, channel opening support is area for enhancement for Oracle's smartcardio implementation.

            Unassigned Unassigned
            dsilaev Dmitri Silaev
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: