Help in starting Java Card Programming

Hi all,
I�m totally new here. I just started Java Card programming. However I don�t know how to start though I think I have enough stuff. I have installed Java 1.6.0_02, JCOP tool 3.1.2, run Eclipse 3.3.0. I also have a dual interface smart card reader SDI010 and some smart card (dual access). I activated JCOP Tool, created new Java Card project, but after I entered package AIDs and applet AIDs I don�t know what I should do next. I looked through several books in Eclipse (Eclipse for dummies�) but can�t find anything about Java Card. Anyone have experience in this area please help me to start. If you know any document that guides step by step, please let me know. I found source code in Sun website (wallet.java) but I really don�t know how to use it. Thanks a lot.

Hi,
select
Project -> Build Automatically. It will build a .CAP file every time you changed your Java Card project code and save it. You will see it in the
CAP file viewer in the left corner (but only in case you are developing your JC applet in Java Card in Eclipse project and opened one of the
JCOP perspectives: either development or debug).
P.S. I suppose, that u still haven't looked through the JCOP tools documentation in the Eclipse IDE Help menu.
Best regards,
Eve
Edited by: Ieva on Nov 4, 2007 9:01 AM

Similar Messages

  • How should i start Java Card Programming?

    Hi All,
    I am a j2me programmer and now would like to learn and develop some applications in JavaCard Technology. but the problem is i dont know how should i start with JavaCard Programming?What all hardwares and softwares will i require for doing JavaCard programming?Can anyone give me some project ideas too for programming in JavaCard Technology
    Thanks
    Sagar

    I think it's best you start here:
    http://java.sun.com/products/javacard/index.jsp
    Some hints about books/specs you can find in this post:
    http://forum.java.sun.com/thread.jspa?forumID=23&threadID=5114170
    There are a variety of Java Card development tools. Just browse through this forum.

  • Need suggestions to start java card prog. plz help!!

    hi ppl....
    I am new to java card programming, but not to java programming. As a starter, i need to know ..... how to write a basic java card app?? Further, i also want to get the knowledge of testing/running this app on any simulator (if available). Can someone tell me that if i need to run my card application on real "smart card" (NOT on simulator), then what i need to have ... i mean any card processor or interface with PC. Any help will be much appreciated.
    Raheel.

    Download the sun kit and read the manuals

  • Java Card program execution on Eclipse

    Hi Dears,
    I am new to Java Card. I did setup to run Java Card programs on eclipse using http://eclipse-jcde.sourceforge.net/.
    This is my simple program below
    import javacard.security.RandomData;
    public class Main {
         public void main() {
              RandomData rd = RandomData.getInstance(RandomData.ALG_SECURE_RANDOM);
              short outLen = 10;
              byte buffer[] = new byte[outLen];
              short outOffset = 0;
              rd.generateData(buffer, outOffset, outLen);
    Compilation is successful but when I run the program I get the following error.
    Error occurred during initialization of VM
    java/lang/NoClassDefFoundError: java/lang/String
    This is very annoying. I think my run time environment is not ok for running java card programs. I am able to run Java programs but not java card programs. Any one can help please?
    Thanks,
    Regards,
    Naveed

    please post code with {code} tags
    Naveed86 wrote:
    Hi Dears,
    I am new to Java Card. I did setup to run Java Card programs on eclipse using http://eclipse-jcde.sourceforge.net/.
    This is my simple program below
    import javacard.security.RandomData;
    public class Main {
         public void main() {
              RandomData rd = RandomData.getInstance(RandomData.ALG_SECURE_RANDOM);
              short outLen = 10;
              byte buffer[] = new byte[outLen];
              short outOffset = 0;
              rd.generateData(buffer, outOffset, outLen);
    }Compilation is successful but when I run the program I get the following error.
    Error occurred during initialization of VM
    java/lang/NoClassDefFoundError: java/lang/String
    This is very annoying. I think my run time environment is not ok for running java card programs. I am able to run Java programs but not java card programs. Any one can help please?
    Thanks,
    Regards,
    Naveed

  • How to start java card development?

    Good Evening all,
    I am novice for java card development , from last some days I study java card and terms related to it, now i have some knowledge about applets , and API. as i read about java card 2 and 3, I think i moved to java card 2 that's why i download jcdk 2.1.
    Now i want to do something in development rather than further conceptual study. Frankly speaking I m confused where to move because different sites have different point of view so i want to execute my knowledge which i earned from last some days...
    so I want to ask
    1- which IDE would be best for java card development? { eclipse or net beans or something other}
    2- what things i would be require during java card application?{ java sdk version? jcdk version? ocf? or what}
    3- at start i want to use simulation technique to test what i made and how its work, so for this which tool or IDE would be best work for me,
    so kindly request you to guide me and show me the path where i can move and achieve what i want..
    ---------------------------------------------------------------------------------------------------Thank you in advance------------------------------------------
    Edited by: 911936 on Feb 2, 2012 10:01 AM

    Hello umer,
    last night it seems very tough to execute sample program of jcdk 2.2 but finally i make it, and i also i got the IDE - net beans that is very good for java card...
    I think i should share my knowledge here for next novice people...
    ----------------------------------------------------------------------------java card development require-------------------------------------------------------------
    Because here we use java for java card so we require
    1- java development kit (JDK) - use below link to get this.
    [get jdk here|http://download.oracle.com/otn-pub/java/jdk/6u30-b12/jdk-6u30-windows-i586.exe]
    2- Java card require java card development kit (JCDK) I think java card version 3 is latest but i used jcdk 2.2.1
    [get jcdk here|http://download.oracle.com/otn-pub/java/java_card_kit/2.2_01/java_card_kit-2_2_01-win-gl.zip]
    now  i think this is enough to start java card development...
    follow below steps
    1- install jdk 6 in c:/java/jdk1.6
    2-keep jcdk in c:/java_card_kit-2_2
    3- open command prompt and run
    a)-set JC_HOME=c:\java_card_kit-2_2
    b)-set JAVA_HOME=c:\java/jdk1.6
    c)-set PATH=%JC_HOME%\bin;%PATH%
    4-there are some sample project in scdk, if you want to get confidence , u should run one of them..
    run command- jcwde jcwde.app { jcwde is a simulator where u check what u made }
    and run this command in another command prompt- apdutool -nobanner -noatr demo1.scr > demo1.scr.jcwde.out
    You can get detail of 3 and 4 step from cJDK_Users_Guide.pdf which is present in jcdk.
    ------------------------this  is all which u need to do to get confidence in java card, but dont be over confident because in reality "the ball is not in your court yet"
    Note- if you are searching which java IDE is best for java card development then
    [click here- this is one of the best ide for java card|http://dlc.sun.com.edgesuite.net/netbeans/7.1/final/bundles/netbeans-7.1-ml-windows.exe]
    Edited by: 911936 on Feb 3, 2012 8:58 AM

  • How to run the simple java card program in eclipse?

    I am trying to run a simple HelloWorld program in eclipse 3.5 having java card development kit 2.2 installed in it.
    Firstly,I go to the JCWDE tab and press start..then when trying to deploy that package its giving me error like " com.hw.HelloWorld: unsupported class file format of version 50.0." can any one help me in this what is this error???n how to resolve n run this program..

    Hi,
    It is because the converter works on byte code and it only supports a subset of the Java language (see the JC specifications). It is kind of like compiling you code on Java 6 and trying to run it on Java 5. The JCDK outlines the required compiler version.
    Cheers,
    Shane

  • How to start with Card programming !

    Hello,
    I want to learn card programming. For this i want to know few things.
    1) Where can i find an IDE to write program ?
    2) Do we get any simulator in it ?
    3) How to compile and run the card program.
    Right now i can not buy a reader or card. Just want to develop in simulator. How to start ?
    Please, help me. I do not know anything about it.
    Thanks,
    Abhijit Chandekar

    I want to learn card programming.http://developers.sun.com/techtopics/mobility/javacard/articles/
    Read "An Introduction to Java Card Technology" Part 1 to 3 for starting with java cards.
    1) Where can i find an IDE to write program ?The JCOP tools plugin for Eclipse is the cheapest IDE i know.
    http://www.zurich.ibm.com/jcop/products/tools.html
    2) Do we get any simulator in it ?Use CREF from the Java card development Kit or the JCOP emulator from the JCOP tools.
    3) How to compile and run the card program.See the Java Card Development Kit User’s Guide that comes with the Java Card JDK.
    @the other forum member:
    May be we should start creating a forum-FAQ which will be posted once a week. That would make it easier to help all the "newbies"...
    Someone interested?
    Jan

  • How to check the output of a java card program ?

    Hi,
    I am new to java card technology.I am trying to run a simple helloworld program given in the java development kit2.2 -windows samples in eclipse3.5.
    For running I followed the following steps:-
    1) Firstly,I went to JCWDE->start
    2) then on Project->java tools->deploy
    It shows me following output :-
    Java Card 2.2.2 APDU Tool, Version 1.3
    Copyright 2005 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.
    Opening connection to localhost on port 9025.
    Connected.
    Received ATR = 0x3b 0xf0 0x11 0x00 0xff 0x00
    CLA: 00, INS: a4, P1: 04, P2: 00, Lc: 09, a0, 00, 00, 00, 62, 03, 01, 08, 01, Le: 00, SW1: 90, SW2: 00
    CLA: 80, INS: b0, P1: 00, P2: 00, Lc: 00, Le: 00, SW1: 90, SW2: 00
    CLA: 80, INS: b2, P1: 01, P2: 00, Lc: 00, Le: 00, SW1: 90, SW2: 00
    CLA: 80, INS: b4, P1: 01, P2: 00, Lc: 18, 01, 00, 15, de, ca, ff, ed, 01, 02, 04, 00, 01, 0b, 01, 02, 03, 04, 05, 06, 07, 08, 09, 00, 01, Le: 00, SW1: 64, SW2: 3a
    CLA: 80, INS: bc, P1: 01, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 02, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 02, P2: 00, Lc: 20, 02, 00, 1f, 00, 15, 00, 1f, 00, 0f, 00, 15, 00, 36, 00, 0c, 00, 69, 00, 0a, 00, 14, 00, 00, 00, 6c, 00, 00, 00, 00, 00, 00, 02, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 02, P2: 00, Lc: 02, 01, 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 02, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 04, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 04, P2: 00, Lc: 18, 04, 00, 15, 02, 03, 01, 07, a0, 00, 00, 00, 62, 01, 01, 00, 01, 07, a0, 00, 00, 00, 62, 00, 01, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 04, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 03, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 03, P2: 00, Lc: 12, 03, 00, 0f, 01, 0b, 01, 02, 03, 04, 05, 06, 07, 08, 09, 00, 00, 00, 14, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 03, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 06, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 06, P2: 00, Lc: 0f, 06, 00, 0c, 00, 80, 03, 01, 00, 01, 07, 01, 00, 00, 00, 21, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 06, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 07, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 07, P2: 00, Lc: 20, 07, 00, 69, 00, 02, 10, 18, 8c, 00, 01, 18, 11, 01, 00, 90, 0b, 87, 00, 18, 8b, 00, 02, 7a, 02, 30, 8f, 00, 03, 3d, 8c, 00, 04, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 07, P2: 00, Lc: 20, 8b, 00, 02, 7a, 05, 23, 19, 8b, 00, 05, 2d, 19, 8b, 00, 06, 32, 03, 29, 04, 70, 19, 1a, 08, ad, 00, 16, 04, 1f, 8d, 00, 0b, 3b, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 07, P2: 00, Lc: 20, 16, 04, 1f, 41, 29, 04, 19, 08, 8b, 00, 0c, 32, 1f, 64, e8, 19, 8b, 00, 07, 3b, 19, 16, 04, 08, 41, 8b, 00, 08, 19, 03, 08, 8b, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 07, P2: 00, Lc: 0c, 00, 09, 19, ad, 00, 03, 16, 04, 8b, 00, 0a, 7a, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 07, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 08, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 08, P2: 00, Lc: 0d, 08, 00, 0a, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 08, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 05, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 05, P2: 00, Lc: 20, 05, 00, 36, 00, 0d, 02, 00, 00, 00, 06, 80, 03, 00, 03, 80, 03, 01, 01, 00, 00, 00, 06, 00, 00, 01, 03, 80, 0a, 01, 03, 80, 0a, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 05, P2: 00, Lc: 19, 06, 03, 80, 0a, 07, 03, 80, 0a, 09, 03, 80, 0a, 04, 03, 80, 0a, 05, 06, 80, 10, 02, 03, 80, 0a, 03, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 05, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b2, P1: 09, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: b4, P1: 09, P2: 00, Lc: 17, 09, 00, 14, 00, 03, 0e, 27, 2c, 00, 0d, 05, 0c, 06, 04, 03, 07, 05, 10, 0c, 08, 09, 06, 09, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: bc, P1: 09, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    CLA: 80, INS: ba, P1: 00, P2: 00, Lc: 00, Le: 00, SW1: 64, SW2: 21
    Can anyone tell me what is this output? And Am i deplyoing in the right way?

    Hi,
    You might want to check the JCDK user guide (cJDK_Users_Guide_bin_do.pdf) for details of using an emulated card environment. It outlines how to use the simulators provided with the JCDK. This should tell you how the deploy process works and will give you some insight into what this script is doing.
    Cheers,
    Shane

  • Why do we need IDE or tools for java card programming?

    Hi,
    I am a newbie to java card, using java card kit tools themself, we can test and burn the code into card right?
    then why do we need IDE for java card, please correct me , if i am wrong,
    Thanks in advance,
    Sri.

    Dear Sri,
    We have compiler, linker etc for every language starting of from C or C++ or Java. JDK has all the tools necessary to develop and run a Java program. Similarly Java Card Development Kit has all the tools for developing and deploying a Java Card applet. But what an IDE does is too integrate all these tools and make it easier for the JavaCard programmer to develop his applets. Just like Eclipse is used for Java applet development.And not everytime the code is burned to the card. Its only during masking code is burned to the card, i.e if u can call it burning. Masking makes an applet permanent on the card.

  • Regarding java card programming

    hi all,
    i am very new to the java card tech. now i want to do a project in the smart card area. how can i ready to programming (downloadables)? i need some basic idea about tools to be downloaded. please provide me some ideas.
    Thanks and Ragards
    __Vasantha kumar

    Start with something more simple. You're just asking
    for trouble trying to start with something "big".Agreed. You may want to make a non-AI version of the game first. In other words, if you want to make a game of blackjack with an AI dealer. First make the blackjack game with no AI. So the user would deal his own cards and decide when to hit, stand, etc... After you understand how to let the player do that, you can move on to dealing with how a computer would do it.

  • How to run Java Card Program in a Simulator

    I m Narendra Reddy studying in India and have taken Java Card for my B.E. final year project.
    i also acquire knowledge of Whole Java Card Development Life Cycle but i found much more difficulties to implement those ideas into java card.
    so, Will you please do me a favour and give me a complete solution if possible with an example.
    i also want each step with the commands, from the creation of Class file to the running of prog. in simulator.
    it will be very useful for me to head towards my project.
    Thank you,

    Just for the record,
    Since we are looking at different possibilities, there are couple of ways to achieve simulation/testing environment for current Java Card,
    1. "The Java Card Workstation Development Environment(JCWDE) tool allows the simulated running of Java Card applet as if it were masked in ROM. It immulates Card environment." Although, as Joe mentioned, it does not support;
    - package installation
    - applet instance creation
    - persistent card state
    - firewall
    - transactions
    - transient array clearing
    - remote method invocation
    - applet/package deletion
    Thus you can use 'jcwde' tool in combination of apdutool to test some
    of the Applet behavior(& JCRE) but not all. You have realized this when you tried 'sample' applets.
    2. JCDK2.2 also provide c-reference implementation of the Java Card. This(cref) is more robust way to test Applet. Although the catch with this is that Sun does not have SCSL(Community Source Licensing) program for Java Card(alas!) and this means you can not mask your applet into this reference implementation unless you get hold of source code somehow(source licensing is one(costly) way)
    3. Buy reader/card and figure out how to install applet for
    testing purpose.
    4. Buy kit from JC vendor containing reader/software/cards and use it
    (costly and hard to find JC2.2 implementation)
    1 and 2 are easier but not a real life solution(how many cards with intel/sparc processor anyway?). 3 and 4 are ideal but other way challenging. Yes, probably solution-1 is the right for your purpose.
    regard,

  • UPDATED: jcManager - Java Card Programming Visual Tool

    UPDATED with the following features, as requested:
    - new and improved GUI
    - possibility to select the reader
    - better output - display all commands sent to card and the replies
    - specify card manager AID
    - specify applet install command parameters
    ... and many more
    [Download here|http://www.brokenmill.com/2010/03/java-secure-card-manager/]
    Enjoy
    Stefan
    ... sorry for the double post...

    Thanks Stefan for your reply..
    i want to know, what versions of Java Card OS that supported by jcManager..
    Currently i use Java Card 2.2.1, but when i tried to load .CAP file using this tool, i always get this error :
    Open terminal ...
    EstablishContext(): ...
    Wait for card in a certain reader ...
    Pick reader ...
    Selecting Card Manager
    -> 00 A4 04 00 08 A0 00 00 00 03 00 00 00
    <- 6F 10 84 08 A0 00 00 00 03 00 00 00 A5 04 9F 65 01 FF 90 00
    Init Update
    -> 80 50 00 00 08 7D 01 2C 52 CB 41 62 FB
    <- 00 00 71 54 57 17 3C 2B 8F C1 FF 02 00 53 CC D9 DE 61 D9 80 8E 65 D6 84 59 F5 DC 7C 90 00
    HostChallenge: 7D 01 2C 52 CB 41 62 FB
    CardChallenge: CC D9 DE 61 D9 80
    Card Calculated Card Cryptogram: 8E 65 D6 84 59 F5 DC 7C
    Derivation Data is 01 82 00 53 00 00 00 00 00 00 00 00 00 00 00 00
    Host Cryptogram Data (to encrypt) 00 53 CC D9 DE 61 D9 80 7D 01 2C 52 CB 41 62 FB 80 00 00 00 00 00 00 00
    Card Cryptogram Data (to encrypt for verification) 7D 01 2C 52 CB 41 62 FB 00 53 CC D9 DE 61 D9 80 80 00 00 00 00 00 00 00
    S_ENC: 03 82 60 2B BA CF 22 AC 27 4F 34 81 E6 66 0E 68 03 82 60 2B BA CF 22 AC
    The Current session MAC key is B3 D1 2B 42 AA 64 C3 A2 84 47 1E E5 AD 6A 01 FB
    The Current session DEK key is 56 47 C9 B7 A9 BC 67 63 1E BE 05 DC 39 1D B4 8B
    Encrypted CardCryptoGram is 3B C0 CF 36 E3 83 D2 38 83 61 10 D8 36 75 5F A7 8E 65 D6 84 59 F5 DC 7C
    Encrypted HostCryptoGram is 6F 72 46 A5 6B 01 64 6E 28 E9 16 1B D7 74 58 14 3E A2 C2 92 53 05 A9 D5
    -> 84 82 03 00 10 3E A2 C2 92 53 05 A9 D5 8E FE D9 90 92 D3 EC 1B
    <- 90 00
    Authenticated
    UplaodCAP
    Get AID from header.cap file
    FOR LOAD DATA: EF 04 C6 02 01 9B
    AID:A0 00 00 00 62 03 01 0C 01
    Applet AID:A0 00 00 00 62 03 01 0C 01 01
    Try to delete if existing...
    -> 84 E4 00 00 18 D6 11 44 FF FD 6D EF 28 70 A1 30 70 ED BA 78 8C B1 DB C6 AF 6C 86 0A A3
    <- 6A 88
    -> 84 E4 00 00 18 2C CA A4 41 C1 05 BD 3F 5E 26 13 D9 A1 AA BD AA B7 0E EF 02 1F CC 55 F9
    <- 6A 88
    Loading cap file. Please wait...
    Install for Load
    -> 84 E6 02 00 28 19 99 78 6D 57 F3 F8 E3 AE 41 D8 00 00 7F 92 5E AD 51 D6 E3 CB 70 D0 B5 9F 8E 19 FD EE 8A 26 37 B0 1D C8 E9 4A ED 9B FC
    <- 00 90 00
    Load CAP
    -> 84 E8 80 00 10 7C 0A D8 32 F3 D6 DF 00 80 BA 28 8F CD 90 02 DD
    <- 6A 80
    -> 84 E6 0C 00 38 19 99 78 6D 57 F3 F8 E3 7F 53 52 F0 15 33 97 38 0E D9 AB B1 12 BB 63 EA F8 6C CB 8B 93 47 DC 6C 88 71 7B F1 F7 25 4E E0 37 40 7F C9 0A 47 94 3F B5 3E 1C B4 4A 4E BC AE
    <- 6A 88
    Could not load applet. See debug for more infoDo you know why?, but it could be strange for me because when i tried to load HelloWorld.cap that shipped with GPShell 1.4.2, it could work well..
    Please help me..
    Thanks in advance..

  • !!Help!![Java Card Platform]Off Card Installer[v3.0.2]Create failed: null

    I newbie used NetBeans to simulator Java Card Platform, and newbie for Java Card.
    I take VERY simple sample HelloWorld and add several lines:
    and launch build.xml with run task.
    all stages goes well, compiling, packaging, loading to simulator, but creation failed!!!!
    import javacard.security.RandomData;
    public class HelloWorld extends Applet {
         private RandomData Rnd ;
         protected HelloWorld() {
              Rnd = RandomData.getInstance(RandomData.ALG_SECURE_RANDOM);
              register();
         public static void install(byte[] bArray, short bOffset, byte bLength) {
              new HelloWorld();
    build.xml(Create-Instance)
    OffCard Installer [v3.0.2]
        Copyright (c) 2009 Sun Microsystems, Inc.
        All rights reserved.
        Use is subject to license terms.
    [ INFO: ] [Creating an instance of HelloWorld with instance ID //aid/A000000062/03010C0101 on http://localhost:8019/cardmanager/]
    [ INFO: ] "Off Card Installer validating create information"
    [ INFO: ] "Off Card Installer preparing create information"
    [ INFO: ] "Off Card Installer sending create request"
    [ INFO: ] Create failed: null
    When I remove this line,
    //Rnd = RandomData.getInstance(RandomData.ALG_SECURE_RANDOM);
    then OffCard Installer will operation completed successfully.
    [ INFO: ] Operation completed successfully.
    WHAT I'm doing wrong?
    Someone can help me!!

    I newbie used NetBeans to simulator Java Card Platform, and newbie for Java Card.
    I take VERY simple sample HelloWorld and add several lines:
    and launch build.xml with run task.
    all stages goes well, compiling, packaging, loading to simulator, but creation failed!!!!
    import javacard.security.RandomData;
    public class HelloWorld extends Applet {
         private RandomData Rnd ;
         protected HelloWorld() {
              Rnd = RandomData.getInstance(RandomData.ALG_SECURE_RANDOM);
              register();
         public static void install(byte[] bArray, short bOffset, byte bLength) {
              new HelloWorld();
    build.xml(Create-Instance)
    OffCard Installer [v3.0.2]
        Copyright (c) 2009 Sun Microsystems, Inc.
        All rights reserved.
        Use is subject to license terms.
    [ INFO: ] [Creating an instance of HelloWorld with instance ID //aid/A000000062/03010C0101 on http://localhost:8019/cardmanager/]
    [ INFO: ] "Off Card Installer validating create information"
    [ INFO: ] "Off Card Installer preparing create information"
    [ INFO: ] "Off Card Installer sending create request"
    [ INFO: ] Create failed: null
    When I remove this line,
    //Rnd = RandomData.getInstance(RandomData.ALG_SECURE_RANDOM);
    then OffCard Installer will operation completed successfully.
    [ INFO: ] Operation completed successfully.
    WHAT I'm doing wrong?
    Someone can help me!!

  • Help about running Java Card developement Kit Demo

    I am following the Java Card development kit step by step. I have set all environments but I could not run the demo at all. D:\JAVACARD\SAMPLES\SRC\DEMO>
    if I type "jcwde jcwde.app" at the demo directory, it tells me that, jcwde is not an intenal or batch file command. when I copied the jcwde.bat from bin directory to demo directory, it run but a lot of erros.
    I will be glad if somebody can help to overcome this initial and very important steps in my adventure to smart card.
    Thanks

    Thanks everybody for their contribution and suggestion. I have been able to make the demo works apart from demo1 which still give problems.
    if I type jcwde jcwde.app, it gives me the following errors.
    Java Card 2.2 Workstation Development Environment (version 0.18).
    Copyright 2002 Sun Microsystems, Inc. All rights reserved.
    jcwde is listening for T=0 Apdu's on TCP/IP port 9,025.
    Exception in thread "main" java.lang.IllegalAccessError: class javacard.framewor
    k.JCWDEDispatcher cannot access its superclass javacard.framework.Dispatcher
    at java.lang.ClassLoader.defineClass0(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:509)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:12
    3)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:246)
    at java.net.URLClassLoader.access$100(URLClassLoader.java:54)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:193)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:186)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:265)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:262)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:322)
    at com.sun.javacard.jcwde.Main.run(Main.java:77)
    at com.sun.javacard.jcwde.Main.main(Main.java:141)

  • Auto start Java Card application

    Hello,
    is it possible to start a Java Card application from the SIM card right after the mobile is switched on?
    I talked to a guy from a SIM card manufacturer and he told me it's possible since the device checks on start if a Java Card application is present to display it in the phone's menu, but it's device dependant how it's done and if the application really will be started (which sounds kind of strange).
    Can someone give me more details if it's possible to auto start a application and how it's done ( code snippet would be great ; )?
    Thanks in advance,
    teric

    The first event after ME startup, which STK applet could catch is Terminal Profile.
    So, in applet class constructor should be smthng like
    ToolkitRegistry reg = ToolkitRegistry.getEntry();
    reg.setEvent(EVENT_PROFILE_DOWNLOAD);
    and applet will trigger on Terminal Profile arrival.

Maybe you are looking for