3 Replies Latest reply: Mar 1, 2012 3:03 PM by safarmer RSS

    java card doubts..

    918703
      Hello all,
      I am trying to understand the concept of java card , I have some doubts , I want to share with , perhaps you would any best suggestion for me.
      //Jcop-  I read somewhere that Java Card OpenPlatform (JCOP) is a smart card operating system for the Java Card platform developed by IBM Zürich Research Laboratory.
      question 1 - if this above sentence is right it means jcop is an operating system developed by IBM, handle all operation inside the card.right? I have a card which indicate
      ATR like- 3b 89 80 01 4a ....40 ( in character form it indicate- ;---jcop41v22m) , so can i say? this is a card which o.s is made by IBM. and we require only and only JCOP tool to send cap inside this card because OS inside is JCOP and jcop tool would be the only option to talk to jCOp card?

      question 2 - or is there any other method by which i can send the applet inside my card?
      enable_trace
      establish_context
      card_connect
      select -AID a0000000030000
      open_sc -security 1 -keyind 0 -keyver 0 -mac_key 404142434445464748494a4b4c4d4e4f -enc_key 404142434445464748494a4b4c4d4e4f // Open secure channel
      delete -AID D0D1D2D3D4D50101
      delete -AID D0D1D2D3D4D501
      delete -AID D0D1D2D3D4D50101
      install -file helloworld.cap -nvDataLimit 500 -instParam 00 -priv 2
      # getdata
      # close_sc // Close secure channel
      # putkey // Put key
        // options:
        //          -keyind Key index
        //          -keyver Key version
        //          -key Key value in hex
      card_disconnect
      release_context
      question 3 - above code i got from gpshell 1.4.4 , the code style indictate that this is also a method tp send cap file inside the java card, I want to know that for my card case { atr is -3b 89 80 01 4a ....40 ( in character form it indicate- ;---jcop41v22m)} , I can apply gpshell to send .cap file in my card.
      question 4 - is gpshell is used to send cap into a special java card which is not jcop enable or which does not contaion jcop operating system?
      there are so many techniques , so many type of java card, it makes me confuse , I hope you seems this question genuine and would give me revert back
      regards:-

      Edited by: daniel on Feb 29, 2012 10:08 AM
        • 1. Re: java card doubts..
          918757
          Alright, I'll awnser your questions my best.

          Question 1 :
          Yes, you could say that. However, i'm using a J2A080 card(JCOP card) and i'm not using the jcop tool kit.
          I use eclipse with EclipseJCRE add on to develop my application, since there is a JavaCard emulator in it, you can test it witout installing your applet everytime you make a modification.

          Question 2-3 :
          GPShell is a nice tool for card communication, but i would also suggest you GPJ. Specially if you start with java cards because it is way more easier. It works with my J2A080 and have been tested with your card type and should work. You just have to generate the cap file with eclipse and load it with GPJ

          Question 4 :
          I'm not sure about that but I think GPShell can works for pretty much all type of card that has OpenPlatform on it.
          But it is more complicated to find the good keys and get the good options at the good places, that is why I recomand you GPJ.


          Hope it helps you out!



          P.S. Pay attention to the JavaCard platform supportd by the card, yours is 2.2.1. If you try to build CAP file with an other version installed, it may not work properly.

          Edited by: FrancisOL on Feb 29, 2012 11:22 AM
          • 2. Re: java card doubts..
            918703
            a huge thanks FrancisOL for your time,
            Really i have a big confusion about things so really it would take some time to sorted out, I think i let you know the things, perhaps you clear my doubts.
            you wrote 1-
            Yes, you could say that. However, i'm using a J2A080 card(JCOP card) and i'm not using the jcop tool kit.
            I use eclipse with EclipseJCRE add on to develop my application, since there is a JavaCard emulator in it, you can test it witout installing your applet everytime you make a modification.
            you means to say you are using ECLIPSE JCDE - java card development envoirnment plugin , which gives jcwe and cref two simulator, IS this way u generate your cap file?
            • 3. Re: java card doubts..
              safarmer
              Hi,

              You can use any tool that supports the GlobalPlatform (GP) card spec that your card is based on. In this case you have a GP 2.1.1 card. GP defines some commands (APDU's) that you can send to the card to manage card content (LOAD INSTALL DELETE etc). The tools mention previously all implement these commands to allow you to load you applets onto your card. The key is to find the tool that fits into your workflow the best. If you jave JCOP cards and an NDA with NXP (they acquired the JCOP platform from IBM some time ago) you can get JCOP tools which is a great tool for JCOP cards as it has the emulator for that platform built in.

              Cheers,
              Shane