Commit cbbd0fbe authored by Josh Ji's avatar Josh Ji

fix incorrect data of IDx in getPuKxRx()

parent 4fe40fff
......@@ -378,8 +378,9 @@ public class CTAP2 extends Applet implements ExtendedLength {
* return: PuKx and Rx in CBOR form
*/
private void getPuKxRx(APDU apdu, short dataLength){
// TODO IDx have to get data from dataBuffer at index 1
idSecret.IDx = new DomString(dataBuffer, dataLength);
// Done IDx have to get data from dataBuffer at index 1
Util.arrayCopy(dataBuffer, (short)1, scratch, (short)0, (short)(dataLength-1));
idSecret.IDx = new DomString(scratch, (short)(dataLength-1) );
cborEncoder.init(dataBuffer, (short) 0, (short)1200);
cborEncoder.startArray((short)2);
cborEncoder.encodeUInt32(idSecret.Rx, (short)0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment