libchipcard 5.1.6
card_imp.h
Go to the documentation of this file.
1/***************************************************************************
2 $RCSfile$
3 -------------------
4 cvs : $Id: card.h 163 2006-02-15 19:31:45Z aquamaniac $
5 begin : Mon Mar 01 2004
6 copyright : (C) 2004 by Martin Preuss
7 email : martin@libchipcard.de
8
9 ***************************************************************************
10 * Please see toplevel file COPYING for license details *
11 ***************************************************************************/
12
13
14#ifndef CHIPCARD_CLIENT_CARD_IMP_H
15#define CHIPCARD_CLIENT_CARD_IMP_H
16
17
21
22#include <chipcard/card.h>
23
24#ifdef __cplusplus
25extern "C" {
26#endif
27
28GWEN_LIST_FUNCTION_LIB_DEFS(LC_CARD, LC_Card, CHIPCARD_API)
29
30
36
39 unsigned int pid,
40 int *maxErrors,
41 int *currentErrors);
42
45 int id,
46 unsigned char *buffer,
47 unsigned int maxLen,
48 unsigned int *pinLength);
49
50
53 uint32_t flags,
54 int offset,
55 int size,
56 GWEN_BUFFER *buf);
57
60 uint32_t flags,
61 int offset,
62 const char *ptr,
63 unsigned int size);
64
65
68 uint32_t flags,
69 int offset,
70 const char *ptr,
71 unsigned int size);
72
75 uint32_t flags,
76 int offset,
77 unsigned int size);
78
81 uint32_t flags,
82 int recNum,
83 GWEN_BUFFER *buf);
84
87 uint32_t flags,
88 int recNum,
89 const char *ptr,
90 unsigned int size);
91
94 uint32_t flags,
95 const char *ptr,
96 unsigned int size);
97
100 uint32_t flags,
101 int recNum,
102 const char *ptr,
103 unsigned int size);
104
107 uint32_t flags,
108 const LC_PININFO *pi,
109 const unsigned char *ptr,
110 unsigned int size,
111 int *triesLeft);
112
115 uint32_t flags,
116 const LC_PININFO *pi,
117 const unsigned char *oldptr,
118 unsigned int oldsize,
119 const unsigned char *newptr,
120 unsigned int newsize,
121 int *triesLeft);
122
125 uint32_t flags,
126 const LC_PININFO *pi,
127 int *triesLeft);
128
131 uint32_t flags,
132 const LC_PININFO *pi,
133 int *triesLeft);
134
135
138 int tmpl,
139 int kids, int kidp,
140 int ar);
141
144 const char *ptr,
145 unsigned int size,
146 GWEN_BUFFER *sigBuf);
147
150 const char *dptr,
151 unsigned int dsize,
152 const char *sigptr,
153 unsigned int sigsize);
154
157 const char *ptr,
158 unsigned int size,
159 GWEN_BUFFER *codeBuf);
160
163 const char *ptr,
164 unsigned int size,
165 GWEN_BUFFER *codeBuf);
166
169 int kid,
170 const unsigned char *ptr,
171 unsigned int size,
172 GWEN_BUFFER *rBuf);
173
175
176
178void LC_Card_SetReaderType(LC_CARD *cd, const char *s);
179
181void LC_Card_SetDriverType(LC_CARD *cd, const char *s);
182
185
187int LC_Card_AddCardType(LC_CARD *cd, const char *s);
188
191 const char *result,
192 const char *text,
193 int sw1, int sw2);
194
195
196
197
204
207
210
213
216
219
222
225
228
231
234
237
240
243
246
249
252
255
258
261
264
268
272
275
278
281
284
287
291
292
294
295
296#ifdef __cplusplus
297}
298#endif
299 /* addtogroup */
301
302#endif /* CHIPCARD_CLIENT_CARD_IMP_H */
303
struct LC_CARD LC_CARD
Definition card.h:25
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOSIGN_FN)(LC_CARD *card, const char *ptr, unsigned int size, GWEN_BUFFER *sigBuf)
Definition card_imp.h:143
CHIPCARD_API void LC_Card_SetIsoVerifyPinFn(LC_CARD *card, LC_CARD_ISOVERIFYPIN_FN f)
CHIPCARD_API void LC_Card_SetGetPinStatusFn(LC_CARD *card, LC_CARD_GETPINSTATUS_FN fn)
CHIPCARD_API void LC_Card_SetIsoDecipherFn(LC_CARD *card, LC_CARD_ISODECIPHER_FN f)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOUPDATEBINARY_FN)(LC_CARD *card, uint32_t flags, int offset, const char *ptr, unsigned int size)
Definition card_imp.h:67
CHIPCARD_API LC_CARD_CLOSE_FN LC_Card_GetCloseFn(const LC_CARD *card)
CHIPCARD_API void LC_Card_SetGetInitialPinFn(LC_CARD *card, LC_CARD_GETINITIALPIN_FN fn)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOUPDATERECORD_FN)(LC_CARD *card, uint32_t flags, int recNum, const char *ptr, unsigned int size)
Definition card_imp.h:99
CHIPCARD_API void LC_Card_SetOpenFn(LC_CARD *card, LC_CARD_OPEN_FN fn)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOPERFORMVERIFICATION_FN)(LC_CARD *card, uint32_t flags, const LC_PININFO *pi, int *triesLeft)
Definition card_imp.h:124
CHIPCARD_API void LC_Card_SetIsoWriteBinaryFn(LC_CARD *card, LC_CARD_ISOWRITEBINARY_FN f)
CHIPCARD_API void LC_Card_SetReaderType(LC_CARD *cd, const char *s)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_GETINITIALPIN_FN)(LC_CARD *card, int id, unsigned char *buffer, unsigned int maxLen, unsigned int *pinLength)
Definition card_imp.h:44
CHIPCARD_API int LC_Card_AddCardType(LC_CARD *cd, const char *s)
CHIPCARD_API void LC_Card_SetIsoWriteRecordFn(LC_CARD *card, LC_CARD_ISOWRITERECORD_FN f)
CHIPCARD_API LC_CARD_OPEN_FN LC_Card_GetOpenFn(const LC_CARD *card)
CHIPCARD_API void LC_Card_SetIsoModifyPinFn(LC_CARD *card, LC_CARD_ISOMODIFYPIN_FN f)
CHIPCARD_API void LC_Card_ResetCardId(LC_CARD *cd)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_OPEN_FN)(LC_CARD *card)
Definition card_imp.h:34
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_GETPINSTATUS_FN)(LC_CARD *card, unsigned int pid, int *maxErrors, int *currentErrors)
Definition card_imp.h:38
CHIPCARD_API void LC_Card_SetIsoUpdateRecordFn(LC_CARD *card, LC_CARD_ISOUPDATERECORD_FN f)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOREADBINARY_FN)(LC_CARD *card, uint32_t flags, int offset, int size, GWEN_BUFFER *buf)
Definition card_imp.h:52
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOAPPENDRECORD_FN)(LC_CARD *card, uint32_t flags, const char *ptr, unsigned int size)
Definition card_imp.h:93
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOWRITEBINARY_FN)(LC_CARD *card, uint32_t flags, int offset, const char *ptr, unsigned int size)
Definition card_imp.h:59
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOINTERNALAUTH_FN)(LC_CARD *card, int kid, const unsigned char *ptr, unsigned int size, GWEN_BUFFER *rBuf)
Definition card_imp.h:168
CHIPCARD_API void LC_Card_SetIsoUpdateBinaryFn(LC_CARD *card, LC_CARD_ISOUPDATEBINARY_FN f)
CHIPCARD_API void LC_Card_SetCloseFn(LC_CARD *card, LC_CARD_CLOSE_FN fn)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOPERFORMMODIFICATION_FN)(LC_CARD *card, uint32_t flags, const LC_PININFO *pi, int *triesLeft)
Definition card_imp.h:130
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOENCIPHER_FN)(LC_CARD *card, const char *ptr, unsigned int size, GWEN_BUFFER *codeBuf)
Definition card_imp.h:156
CHIPCARD_API void LC_Card_SetLastResult(LC_CARD *cd, const char *result, const char *text, int sw1, int sw2)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOERASEBINARY_FN)(LC_CARD *card, uint32_t flags, int offset, unsigned int size)
Definition card_imp.h:74
CHIPCARD_API void LC_Card_SetIsoAppendRecordFn(LC_CARD *card, LC_CARD_ISOAPPENDRECORD_FN f)
CHIPCARD_API void LC_Card_SetIsoReadRecordFn(LC_CARD *card, LC_CARD_ISOREADRECORD_FN f)
CHIPCARD_API void LC_Card_SetDriverType(LC_CARD *cd, const char *s)
CHIPCARD_API void LC_Card_SetIsoPerformModificationFn(LC_CARD *card, LC_CARD_ISOPERFORMMODIFICATION_FN f)
CHIPCARD_API void LC_Card_SetIsoSignFn(LC_CARD *card, LC_CARD_ISOSIGN_FN f)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOMANAGESE_FN)(LC_CARD *card, int tmpl, int kids, int kidp, int ar)
Definition card_imp.h:137
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOMODIFYPIN_FN)(LC_CARD *card, uint32_t flags, const LC_PININFO *pi, const unsigned char *oldptr, unsigned int oldsize, const unsigned char *newptr, unsigned int newsize, int *triesLeft)
Definition card_imp.h:114
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_CLOSE_FN)(LC_CARD *card)
Definition card_imp.h:35
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOREADRECORD_FN)(LC_CARD *card, uint32_t flags, int recNum, GWEN_BUFFER *buf)
Definition card_imp.h:80
CHIPCARD_API void LC_Card_SetIsoVerifyFn(LC_CARD *card, LC_CARD_ISOVERIFY_FN f)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOWRITERECORD_FN)(LC_CARD *card, uint32_t flags, int recNum, const char *ptr, unsigned int size)
Definition card_imp.h:86
CHIPCARD_API void LC_Card_SetIsoReadBinaryFn(LC_CARD *card, LC_CARD_ISOREADBINARY_FN f)
CHIPCARD_API void LC_Card_SetIsoManageSeFn(LC_CARD *card, LC_CARD_ISOMANAGESE_FN f)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISODECIPHER_FN)(LC_CARD *card, const char *ptr, unsigned int size, GWEN_BUFFER *codeBuf)
Definition card_imp.h:162
CHIPCARD_API void LC_Card_SetIsoEraseBinaryFn(LC_CARD *card, LC_CARD_ISOERASEBINARY_FN f)
CHIPCARD_API void LC_Card_SetIsoPerformVerificationFn(LC_CARD *card, LC_CARD_ISOPERFORMVERIFICATION_FN f)
CHIPCARD_API void LC_Card_SetIsoInternalAuthFn(LC_CARD *card, LC_CARD_ISOINTERNALAUTH_FN f)
CHIPCARD_API void LC_Card_SetIsoEncipherFn(LC_CARD *card, LC_CARD_ISOENCIPHER_FN f)
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOVERIFYPIN_FN)(LC_CARD *card, uint32_t flags, const LC_PININFO *pi, const unsigned char *ptr, unsigned int size, int *triesLeft)
Definition card_imp.h:106
LC_CLIENT_RESULT CHIPCARD_CB(* LC_CARD_ISOVERIFY_FN)(LC_CARD *card, const char *dptr, unsigned int dsize, const char *sigptr, unsigned int sigsize)
Definition card_imp.h:149
#define CHIPCARD_CB
Definition chipcard.h:67
#define CHIPCARD_API
Definition chipcard.h:50
LC_CLIENT_RESULT
Definition client.h:40
struct LC_PININFO LC_PININFO
Definition pininfo.h:77