[Muscle] GP lib patch (again).

Peter Williams home_pw at msn.com
Sun Mar 30 21:57:01 PDT 2008


I recommending considering the thrust of the patch below, diff'ed against the current CVS root of the GlobalPlatform library, as used by GPShell. The change fixes the code so put key works on 201 cards ...by ensuring now that the correct 0x81 code is used for the DES3 algid for a key.

I noted that there is a OpenPlatform module in the CVS tree. I have not investigated what it is - or whether it perhaps links against GPShell. If it does, perhaps it already provides a working put key for 201 cards.

===================================================================
RCS file: /cvsroot/globalplatform/GlobalPlatform2.1.1/GlobalPlatform.c,v
retrieving revision 1.39
diff -u -r1.39 GlobalPlatform.c
--- GlobalPlatform.c   25 Mar 2008 23:02:45 -0000   1.39
+++ GlobalPlatform.c   31 Mar 2008 03:37:42 -0000
@@ -279,8 +279,13 @@
 static DWORD traceEnable; //!< Enable trace mode.
 static FILE *traceFile; //!< The trace file for trace mode.
 
+#ifdef _201FIX
+#define OP201 OP_201 //!< Operation mode for OpenPlatform 2.0.1'
+#define GP211 GP_211 //!< Operation mode for GlobalPlatform 2.1.1
+#else
 #define OP201 0x01 //!< Operation mode for OpenPlatform 2.0.1'
 #define GP211 0x02 //!< Operation mode for GlobalPlatform 2.1.1
+#endif
 
 static void mapOP201ToGP211SecurityInfo(OP201_SECURITY_INFO op201secInfo,
                               GP211_SECURITY_INFO *gp211secInfo) {

Success, CVS operation completed
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.drizzle.com/pipermail/muscle/attachments/20080330/abf1c645/attachment.html


More information about the Muscle mailing list