[Pcsclite-cvs-commit] r1706 - in trunk/HandlerTest/JavaCard: . src/org/debian/alioth/pcsclite/readertest

Ludovic Rousseau rousseau at costa.debian.org
Wed Nov 16 07:20:41 UTC 2005


Author: rousseau
Date: 2005-11-16 07:20:39 +0000 (Wed, 16 Nov 2005)
New Revision: 1706

Modified:
   trunk/HandlerTest/JavaCard/rad.gxp
   trunk/HandlerTest/JavaCard/src/org/debian/alioth/pcsclite/readertest/readertest.java
Log:
debug INS_VERIFY_PIN_DUMP


Modified: trunk/HandlerTest/JavaCard/rad.gxp
===================================================================
--- trunk/HandlerTest/JavaCard/rad.gxp	2005-11-15 11:04:35 UTC (rev 1705)
+++ trunk/HandlerTest/JavaCard/rad.gxp	2005-11-16 07:20:39 UTC (rev 1706)
@@ -7,7 +7,13 @@
     <SourceAttributes/>
     <PackageName>org.debian.alioth.pcsclite.readertest</PackageName>
     <ClassFilePath>.\out</ClassFilePath>
-    <SupportedCard disabled="false" name="GXP211v2_IS" supportedInteger="false">
-        <OutputFilePath>.\oncard\GXP211v2_IS</OutputFilePath>
+    <SupportedCard disabled="false" name="GXP211_PK" supportedInteger="false">
+        <OutputFilePath>.\oncard\GXP211_PK</OutputFilePath>
     </SupportedCard>
+    <SupportedCard disabled="false" name="GXP211_PK_IS" supportedInteger="false">
+        <OutputFilePath>.\oncard\GXP211_PK_IS</OutputFilePath>
+    </SupportedCard>
+    <SupportedCard disabled="false" name="GXPPro-R3" supportedInteger="false">
+        <OutputFilePath>.\oncard\GXPPro-R3</OutputFilePath>
+    </SupportedCard>
 </GemXpressoProject>

Modified: trunk/HandlerTest/JavaCard/src/org/debian/alioth/pcsclite/readertest/readertest.java
===================================================================
--- trunk/HandlerTest/JavaCard/src/org/debian/alioth/pcsclite/readertest/readertest.java	2005-11-15 11:04:35 UTC (rev 1705)
+++ trunk/HandlerTest/JavaCard/src/org/debian/alioth/pcsclite/readertest/readertest.java	2005-11-16 07:20:39 UTC (rev 1706)
@@ -60,6 +60,7 @@
      };
 
 	private byte pbMemory[];
+	private short pbMemoryLength;
 
     /**
      * readertest default constructor
@@ -296,7 +297,7 @@
             case INS_VERIFY_PIN:
 	      // Memorize APDU header
 	      Util.arrayCopy(apduBuffer, (short)0, pbMemory, (short)0,
-		(short)4);
+		(short)5);
 
               // Incoming Data length
               bytesLeft = (short) (apduBuffer[ISO7816.OFFSET_LC]
@@ -312,6 +313,7 @@
 	      // Memorize the command
 	      Util.arrayCopy(apduBuffer, (short)ISO7816.OFFSET_CDATA,
 		  pbMemory, (short)ISO7816.OFFSET_CDATA, (short)readCount);
+	      pbMemoryLength = (short)(bytesLeft+5);
 
               while ( bytesLeft > 0 )
               {
@@ -334,17 +336,14 @@
 		    (short)readCount);
 	      }
 
-	      // Memorise the command
-	      Util.arrayCopy(apduBuffer, (short)0, pbMemory, (short)0,
-		  (short)(bytesLeft+4));
             break;
 
             case INS_VERIFY_PIN_DUMP:
               // Outgoing Data length
               le = apdu.setOutgoing();
 
-              apdu.setOutgoingLength (le);
-              apdu.sendBytesLong(pbMemory, (short)0, le);
+              apdu.setOutgoingLength (pbMemoryLength);
+              apdu.sendBytesLong(pbMemory, (short)0, pbMemoryLength);
             break;
 
             default:




More information about the Pcsclite-cvs-commit mailing list