Skip to Main Content

Java Card

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

converting string and decimal values from Host app to hex for APDU..

843851Mar 30 2005 — edited Oct 26 2005
Hi,
I am writing a host appliication for a Java Card applet in which the user types in the PIN value to be checked by the card. I am stuck on how to convert "a1b2c3" that the user types in into a series of bytes for my APDU data to be sent to the card.
I know from conversion charts that the conversion needs to result in
a - 0x61
1 - 0x01
b - 0x62
2 - 0x02
c - 0x63
3 - 0x03
Can anyone point me in the direction of how to take care of this. I am writing my host app using Java and JCOP offcard tools.

Thanks in advance,
Ann
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 23 2005
Added on Mar 30 2005
7 comments
442 views