how to store data,key,cert,... in javacard
I'm newbie in javacard
I develop it by use RMI model
I develop to similar EMV specification but don't exactly
EMV spec told me that data element such as KEY, CERT,COUNTER,ExpirationDate,...anything. will be keep in file , with tree structure.
above is not importance
I try to understand:How to save file into javacard?
I read a lot of help and manual from sdk , this website ,forum
and I feel it'simpossible to save file (such as text file *.txt, photo file *.jpeg,*.gif) into javacard directly,
Is my understand correct?
I try to understand PhotoCardApplet Demo that come with sdk
run it , have fun with it, try to understand code
I saw the demo bring the pictures file from reader-side save into card to the"Object" of byte[]
Is there just only one way to keep KEY,CERT,..DATA in Object in the applet?
Can it possible to seperate these data away from applet and keep it individual? ( seperate applet , text file ,photo file ,... keep in javacard)
And if it possible plz tell me how to do it with detailed.
thx for every answer.
> EMV spec told me that data element such as KEY,
> CERT,COUNTER,ExpirationDate,...anything. will be
> keep in file , with tree structure.
That is the file-system part of an EMV smart card. That has nothing (directly) to do with java cards. Most java cards has a file system part, too but that isn't accessible from within the java card applet.
> I try to understand PhotoCardApplet Demo that come
> with sdk
> run it , have fun with it, try to understand code
> I saw the demo bring the pictures file from
> reader-side save into card to the "Object" of
> byte[]
>
> Is there just only one way to keep KEY,CERT,..DATA
> in Object in the applet?
> Can it possible to seperate these data away from
> applet and keep it individual? ( seperate applet ,
> text file ,photo file ,... keep in javacard)
No, loading data into the memory which belongs to your java card applet instance makes the data become a part of the applet. If you delete the applet all stored data will be deleted, too.
You can only separate different objects within your applet by using separate byte-arrays or other java card objects.
Jan