2.2.2.17 State_Call

The State_Call structure defines parameters to the State call (as specified in section 3.1.4.40) for querying the contents of a smart card reader.

 typedef struct _State_Call {
   REDIR_SCARDHANDLE hCard;
   long fpbAtrIsNULL;
   unsigned long cbAtrLen;
 } State_Call;

hCard: A handle, as specified in section 2.2.1.2.

fpbAtrIsNULL: A Boolean value specifying whether the caller wants to retrieve the length of the data. Set to FALSE (0x00000000) to allow the data to be returned. Set to TRUE (0x00000001), and only the length of the data will be returned. SHOULD be set to TRUE if cbAtrLen is set to SCARD_AUTOALLOCATE (0xFFFFFFFF).

Name

Value

FALSE

0x00000000

TRUE

0x00000001

cbAtrLen: The length of the buffer specified on the TS server side. If cbAtrLen is set to SCARD_AUTOALLOCATE with a value of 0xFFFFFFFF, an array of any length can be returned. Otherwise, the returned array MUST NOT exceed cbAtrLen bytes in length. When the array to be returned exceeds cbAtrLen bytes in length, State_Return.ReturnCode MUST be set to SCARD_E_INSUFFICIENT_BUFFER (0x80100008). Also, cbAtrLen is ignored if fpbAtrIsNULL is set to TRUE (0x00000001). If fpbAtrIsNULL is set to FALSE (0x00000000) but cbAtrLen is set to 0x00000000, then the call MUST succeed, State_Return.cbAtrLen MUST be set to the length of the data in bytes, and State_Return.rgAtr MUST be set to NULL.