|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.cryptware.jcardosapi.CardOS
public class CardOS
Base class for all CardOS based smart cards
Field Summary | |
---|---|
static byte |
SELECT_MODE_ABSOLUTE
Select EF or DF by absolute path selection. |
static byte |
SELECT_MODE_BY_AID
DF Selection by AID DF Data fiels is the AID (1..16 bytes) |
static byte |
SELECT_MODE_NORMAL
Selection of the EF or the DF with the given FID under the current DF - Data field contains the File ID (2 bytes) or Selection of the MF. |
static byte |
SELECT_MODE_PARENT
Selection of the parent DF. |
static byte |
SELECT_MODE_RELATIVE
Select EF or DF by relative path selection. |
Constructor Summary | |
---|---|
CardOS(SmartCard sc)
Construct a CNS object |
Method Summary | |
---|---|
ResponseAPDU |
ChangeReferenceData(byte id,
java.lang.String pin)
Change the Reference Data of a PIN object This function needs that the PIN object has been verified before |
ResponseAPDU |
ChangeReferenceData(byte id,
java.lang.String oldpin,
java.lang.String newpin)
Change the Reference Data of PIN object |
ResponseAPDU |
ReadBinary(byte hi,
byte low,
short len)
Reads bytes from the currently selected file |
byte[] |
ReadBinary(int toRead)
Reads bytes from the currently selected file |
ResponseAPDU |
SelectFile(byte mode,
java.lang.String path)
Selects the file given in tha path |
ResponseAPDU |
UpdateBinary(byte hi,
byte low,
byte[] toWrite,
short offset,
short len)
UpdateBinary Command Sends a Update Binary Command APDU with specified offset and data |
ResponseAPDU |
UpdateBinary(short hi,
short low,
byte[] toWrite)
UpdateBinary Command Sends a Update Binary Command APDU with specified offset and data |
ResponseAPDU |
VerifyPIN(byte id,
java.lang.String pin)
VerifyPIN Command |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final byte SELECT_MODE_NORMAL
public static final byte SELECT_MODE_PARENT
public static final byte SELECT_MODE_BY_AID
public static final byte SELECT_MODE_ABSOLUTE
public static final byte SELECT_MODE_RELATIVE
Constructor Detail |
---|
public CardOS(SmartCard sc)
sc
- the smart cardMethod Detail |
---|
public ResponseAPDU VerifyPIN(byte id, java.lang.String pin)
id
- the id to verifypin
-
public ResponseAPDU ChangeReferenceData(byte id, java.lang.String pin)
id
- the id of the PIN objectpin
- the new PIN object to set
public ResponseAPDU ChangeReferenceData(byte id, java.lang.String oldpin, java.lang.String newpin)
id
- the id of the PIN objectoldpin
- the old PIN object to changenewpin
- the new PIN object
public ResponseAPDU SelectFile(byte mode, java.lang.String path)
mode
- Selection Mode:
path
- the file path
public byte[] ReadBinary(int toRead) throws SmartCardException
toRead
- Number of bytes to read
SmartCardException
public ResponseAPDU ReadBinary(byte hi, byte low, short len)
hi
- highest byte of the offsetlow
- offset lowest byte of the offsetlen
- number of bytes to read
public ResponseAPDU UpdateBinary(byte hi, byte low, byte[] toWrite, short offset, short len)
hi
- highest byte of the offsetlow
- offset lowest byte of the offsettoWrite
- bytes to writeoffset
- the offset in toWritelen
- the number of bytes to write
public ResponseAPDU UpdateBinary(short hi, short low, byte[] toWrite)
hi
- highest byte of the offsetlow
- offset lowest byte of the offsettoWrite
- bytes to write
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |