Re: MUSCLE CT-API test utility ?

1999-04-01 Thread Carlos Prados

Hi,

I've a implementation of xcard that works with my ctapi driver. In fact
it's just a mapping from DBI-ISO interface used by original xcard to
ct-api.

The link on the web site is broken. It's now located under:

http://pcsc.virtualdave.com/~cprados

as well as newer towitoko driver (1.0).

But I don't think it's a good tester application. It'll work if the driver
is fine but will not detect many driver faliures. Use it at your choice.

On Thu, 1 Apr 1999, Philippe MARTIN wrote:

> Hello,
> 
>  I just subscribe for this list, because as a developer for a French 
> manufacturer, I need to develop a driver for a Philips TDA86006 card
> reader
> (on serial port).
> 
>  I would like to know if some test utilities exist which test the good
> implementation
> of the CT-API standards in my driver.
>  It seems that the XCard app. could do this, but I can't get it
> anywhere.
> 
> Thanks,
> 
> -
> Philippe
> ERIDAN Informatique
> ***
> Linux Smart Card Developers - M.U.S.C.L.E.
> (Movement for the Use of Smart Cards in a Linux Environment)
> http://www.linuxnet.com/smartcard/index.html
> ***
> 

***
Linux Smart Card Developers - M.U.S.C.L.E.
(Movement for the Use of Smart Cards in a Linux Environment)
http://www.linuxnet.com/smartcard/index.html
***



Re: MUSCLE CT-API test utility ?

1999-04-01 Thread David Corcoran

Hello,

As of now - no real test application exists though it exists on my list of
things to do.  Basically you need to test the following:

CT_Init() Does it open the specified port ?
CT_Data() :

Put a Card in - does the CTBCS command return the correct card status ?

Remove the card - does it return the correct card status ?

Power Up - Does the CTBCS command for power up work ?

Reset the Card - Does it return a valid ATR.
( Here is where I have been laxed.  I always return an ATR no matter how
the Reset is called in the CTBCS.  There are several options you can
specify - some which don't send back the ATR.  I ignore this )

Send 3 types of commands using CT_Data():

Case 1: only 5 bytes, no return
Case 2: send 5 bytes plus more such as write Binary, Create, or Select.
Case 3: send 5 bytes which returns more than the 2 status bytes 
( Read Binary )

Power Down - send the CTBCS for Power Down of the reader/card.

CT_close() - does it close the port ?

These are the basics.  If these work than my IFD_Handler wrapper for
CT-API will work.  The IFD_Handler will be changing a bit soon.  Currently
I keep track of the sharing there which is not good.  I've implemented a
Reader Factory which keeps track of sharing and will soon use Unix
authentication to keep track of user priveledges such as if user corcoran
verifies a CHV and then tries to use it at a later date that is OK.  If
user bob decides to use the reader shortly after user corcoran the reader
will be reset to not allow bob to have access to those same CHV's.  It
will be an abstracted layer so porting to the Macintosh won't be such a
pain.

I hope to make a new release towards the end of this week with a C style
API that is identical to Microsoft's.  I'm including it in the next email.

Thanks
Dave

*
David Corcoran Internet Security/Smartcards

Home:  Purdue University
2252 US Highway 52 WestDepartment of Computer Science
West Lafayette, IN 47906   CERIAS/COAST Laboratory
Home: (765) 463-2455
Cell: (317) 514-4797

http://www.linuxnet.com

*


***
Linux Smart Card Developers - M.U.S.C.L.E.
(Movement for the Use of Smart Cards in a Linux Environment)
http://www.linuxnet.com/smartcard/index.html
***



MUSCLE New C style API

1999-04-01 Thread David Corcoran

Hello,

Here is the new C-style API that will be provided with the new release
upcoming early next week.  It is identical to that on the Microsoft system
and all you have to do is #include  and link to libpcsc.


  LONG SCardEstablishContext( 
 DWORD dwScope, 
 LPCVOID pvReserved1, 
 LPCVOID pvReserved2,
 LPSCARDCONTEXT phContext
 );
  
  LONG SCardReleaseContext( 
   SCARDCONTEXT hContext
   );

  LONG SCardListReaderGroupsA( 
  SCARDCONTEXT hContext, 
  LPSTR mszGroups, 
  LPDWORD pcchGroups
  );
  
  LONG SCardListReaders( 
SCARDCONTEXT hContext, 
LPCSTR mszGroups, 
LPSTR mszReaders, 
LPDWORD pcchReaders
);

  LONG SCardListCards( 
  SCARDCONTEXT hContext, 
  LPCBYTE pbAtr, 
  LPCGUID rgquidInterfaces,
  DWORD cguidInterfaceCount, 
  LPSTR mszCards, 
  LPDWORD pcchCards
  );

  LONG SCardListInterfaces( 
   SCARDCONTEXT hContext, 
   LPCSTR szCard, 
   LPGUID pguidInterfaces,
   LPDWORD pcguidInterfaces
   );

  LONG SCardGetProviderId( 
  SCARDCONTEXT hContext, 
  LPCSTR szCard, 
  LPGUID pguidProviderId
  );

  LONG SCardGetCardTypeProviderName( 
SCARDCONTEXT hContext, 
LPCSTR szCardName, 
DWORD dwProviderId,
LPSTR szProvider, 
LPDWORD pcchProvider
);

  LONG SCardIntroduceReaderGroup( 
 SCARDCONTEXT hContext, 
 LPCSTR szGroupName
 );

  LONG SCardForgetReaderGroup(
  SCARDCONTEXT hContext, 
  LPCSTR szGroupName
  );

  LONG SCardIntroduceReader(
SCARDCONTEXT hContext, 
LPCSTR szReaderName, 
LPCSTR szDeviceName
);

  LONG SCardForgetReader(
 SCARDCONTEXT hContext, 
 LPCSTR szReaderName
 );
  
  LONG SCardAddReaderToGroup(
 SCARDCONTEXT hContext, 
 LPCSTR szReaderName, 
 LPCSTR szGroupName
 );

  LONG SCardRemoveReaderFromGroup(
  SCARDCONTEXT hContext, 
  LPCSTR szReaderName, 
  LPCSTR szGroupName
  );

  LONG SCardIntroduceCardType(
  SCARDCONTEXT hContext, 
  LPCSTR szCardName, 
  LPCGUID pguidPrimaryProvider,
  LPCGUID rgguidInterfaces, 
  DWORD dwInterfaceCount, 
  LPCBYTE pbAtr,
  LPCBYTE pbAtrMask, 
  DWORD cbAtrLen
  );

  LONG SCardSetCardTypeProviderName(
SCARDCONTEXT hContext, 
LPCSTR szCardName, 
DWORD dwProviderId,
LPCSTR szProvider
);

  LONG SCardForgetCardType(
   SCARDCONTEXT hContext, 
   LPCSTR szCardName
   );

  LONG SCardFreeMemory(
   SCARDCONTEXT hContext, 
   LPVOID pvMem
   );
  
  LONG SCardLocateCards(
SCARDCONTEXT hContext, 
LPCSTR mszCards, 
LPSCARD_READERSTATE_A rgReaderStates, 
DWORD cReaders
);

  LONG SCardGetStatusChange(
SCARDCONTEXT hContext, 
DWORD dwTimeout, 
LPSCARD_READERSTATE_A rgReaderStates,
DWORD cReaders
);

  LONG SCardCancel(
   SCARDCONTEXT hContext
   

MUSCLE CT-API test utility ?

1999-04-01 Thread Philippe MARTIN

Hello,

 I just subscribe for this list, because as a developer for a French 
manufacturer, I need to develop a driver for a Philips TDA86006 card
reader
(on serial port).

 I would like to know if some test utilities exist which test the good
implementation
of the CT-API standards in my driver.
 It seems that the XCard app. could do this, but I can't get it
anywhere.

Thanks,

-
Philippe
ERIDAN Informatique
***
Linux Smart Card Developers - M.U.S.C.L.E.
(Movement for the Use of Smart Cards in a Linux Environment)
http://www.linuxnet.com/smartcard/index.html
***