2011/4/22 Ludovic Rousseau <[email protected]>:
> 2011/4/22 Björn K. <[email protected]>:
>> Hello,
>
> Hi,
>
>> I'm trying to write an IFD Driver for a virtual smart card reader for
>> Mac OS 10.6.7.
>> At the moment my driver only provides an ATR (borrowed from a DESfire
>> card) and responses to every request in the same way.
>>
>> After virtually inserting the card, tokend and securityd try to
>> communicate with the card, but the TxLength parameter in
>> IFDHTransmitToICC doesn't make any sense to me.
>> I get values like 3741680 (pcscd-log: http://pastebin.com/Mh9DZBgS ).
>> However TxBuffer seems to be the length instead of a pointer to a buffer.
>>
>> This is my ifdhandler.c: http://pastebin.com/nSQjCCF7
>> I compile it with "cc ifdhandler.c -o ifdhandler.dylib -dynamiclib
>> -std=c99" and load it via reader.conf as a serial reader.
>>
>> Am I misunderstanding the TxLength parameter or is there a bug in my code?
>
> I guess you are not using the correct definition for DWORD. Mac OS X
> does not use "unsigned long" but "uint32_t"

Yes, that was in fact the problem. Now it works fine.
Thank you.

Regards

> Have a look at the header files in
> /System/Library/Frameworks/PCSC.framework/Headers
>
> You can also have a look at
> http://smartcardservices.macosforge.org/trac/browser/trunk/SmartCardServices/src/PCSC
>
> Bye
>
> --
>  Dr. Ludovic Rousseau
>
> _______________________________________________
> Muscle mailing list
> [email protected]
> http://lists.drizzle.com/mailman/listinfo/muscle
>

_______________________________________________
Muscle mailing list
[email protected]
http://lists.drizzle.com/mailman/listinfo/muscle

Reply via email to