Lines Matching refs:p_data
144 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(data.size() * sizeof(uint8_t)); in transmit()
145 memcpy(cmdApdu.p_data, data.data(), cmdApdu.len); in transmit()
154 memcpy(&result[0], rspApdu.p_data, rspApdu.len); in transmit()
157 phNxpEse_free(cmdApdu.p_data); in transmit()
158 phNxpEse_free(rspApdu.p_data); in transmit()
189 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(manageChannelCommand.size() * in openLogicalChannel()
191 if (cmdApdu.p_data != NULL) { in openLogicalChannel()
192 memcpy(cmdApdu.p_data, manageChannelCommand.data(), cmdApdu.len); in openLogicalChannel()
198 } else if (rspApdu.p_data[rspApdu.len - 2] == 0x90 && in openLogicalChannel()
199 rspApdu.p_data[rspApdu.len - 1] == 0x00) { in openLogicalChannel()
201 resApduBuff.channelNumber = rspApdu.p_data[0]; in openLogicalChannel()
205 } else if (rspApdu.p_data[rspApdu.len - 2] == 0x6A && in openLogicalChannel()
206 rspApdu.p_data[rspApdu.len - 1] == 0x81) { in openLogicalChannel()
208 } else if (((rspApdu.p_data[rspApdu.len - 2] == 0x6E) || in openLogicalChannel()
209 (rspApdu.p_data[rspApdu.len - 2] == 0x6D)) && in openLogicalChannel()
210 rspApdu.p_data[rspApdu.len - 1] == 0x00) { in openLogicalChannel()
215 phNxpEse_free(cmdApdu.p_data); in openLogicalChannel()
216 phNxpEse_free(rspApdu.p_data); in openLogicalChannel()
241 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(cmdApdu.len * sizeof(uint8_t)); in openLogicalChannel()
242 if (cmdApdu.p_data != NULL) { in openLogicalChannel()
244 cmdApdu.p_data[xx++] = resApduBuff.channelNumber; in openLogicalChannel()
245 cmdApdu.p_data[xx++] = 0xA4; // INS in openLogicalChannel()
246 cmdApdu.p_data[xx++] = 0x04; // P1 in openLogicalChannel()
247 cmdApdu.p_data[xx++] = p2; // P2 in openLogicalChannel()
248 cmdApdu.p_data[xx++] = aid.size(); // Lc in openLogicalChannel()
249 memcpy(&cmdApdu.p_data[xx], aid.data(), aid.size()); in openLogicalChannel()
258 uint8_t sw1 = rspApdu.p_data[rspApdu.len - 2]; in openLogicalChannel()
259 uint8_t sw2 = rspApdu.p_data[rspApdu.len - 1]; in openLogicalChannel()
265 memcpy(&resApduBuff.selectResponse[0], rspApdu.p_data, rspApdu.len); in openLogicalChannel()
289 phNxpEse_free(cmdApdu.p_data); in openLogicalChannel()
290 phNxpEse_free(rspApdu.p_data); in openLogicalChannel()
318 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(cmdApdu.len * sizeof(uint8_t)); in openBasicChannel()
319 if (cmdApdu.p_data != NULL) { in openBasicChannel()
321 cmdApdu.p_data[xx++] = 0x00; // basic channel in openBasicChannel()
322 cmdApdu.p_data[xx++] = 0xA4; // INS in openBasicChannel()
323 cmdApdu.p_data[xx++] = 0x04; // P1 in openBasicChannel()
324 cmdApdu.p_data[xx++] = p2; // P2 in openBasicChannel()
325 cmdApdu.p_data[xx++] = aid.size(); // Lc in openBasicChannel()
326 memcpy(&cmdApdu.p_data[xx], aid.data(), aid.size()); in openBasicChannel()
335 uint8_t sw1 = rspApdu.p_data[rspApdu.len - 2]; in openBasicChannel()
336 uint8_t sw2 = rspApdu.p_data[rspApdu.len - 1]; in openBasicChannel()
342 memcpy(&result[0], rspApdu.p_data, rspApdu.len); in openBasicChannel()
375 phNxpEse_free(cmdApdu.p_data); in openBasicChannel()
376 phNxpEse_free(rspApdu.p_data); in openBasicChannel()
395 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(5 * sizeof(uint8_t)); in closeChannel()
396 if (cmdApdu.p_data != NULL) { in closeChannel()
399 cmdApdu.p_data[xx++] = channelNumber; in closeChannel()
400 cmdApdu.p_data[xx++] = 0x70; // INS in closeChannel()
401 cmdApdu.p_data[xx++] = 0x80; // P1 in closeChannel()
402 cmdApdu.p_data[xx++] = channelNumber; // P2 in closeChannel()
403 cmdApdu.p_data[xx++] = 0x00; // Lc in closeChannel()
410 } else if ((rspApdu.p_data[rspApdu.len - 2] == 0x90) && in closeChannel()
411 (rspApdu.p_data[rspApdu.len - 1] == 0x00)) { in closeChannel()
416 phNxpEse_free(cmdApdu.p_data); in closeChannel()
417 phNxpEse_free(rspApdu.p_data); in closeChannel()