Home
last modified time | relevance | path

Searched refs:cmdApdu (Results 1 – 8 of 8) sorted by relevance

/hardware/st/secure_element/ese-spi-driver/utils-lib/
DCommandApdu.cc34 int CommandApdu_toByteArray(CommandApdu cmdApdu, char* commandApduArray) { in CommandApdu_toByteArray() argument
35 int commandApduArraySize = CommandApdu_getSize(cmdApdu); in CommandApdu_toByteArray()
37 if (cmdApdu.lc > MAX_CMD_APDU_DATA_LENGTH) { in CommandApdu_toByteArray()
41 commandApduArray[0] = cmdApdu.cla; in CommandApdu_toByteArray()
42 commandApduArray[1] = cmdApdu.ins; in CommandApdu_toByteArray()
43 commandApduArray[2] = cmdApdu.p1; in CommandApdu_toByteArray()
44 commandApduArray[3] = cmdApdu.p2; in CommandApdu_toByteArray()
46 if (cmdApdu.lc > 0) { in CommandApdu_toByteArray()
47 commandApduArray[4] = cmdApdu.lc; in CommandApdu_toByteArray()
48 memcpy(commandApduArray + 5, cmdApdu.data, cmdApdu.lc); in CommandApdu_toByteArray()
[all …]
DCommandApdu.h43 int CommandApdu_toByteArray(CommandApdu cmdApdu, char* CommandApduArray);
50 int CommandApdu_getSize(CommandApdu cmdApdu);
65 char* cmdData, char le, CommandApdu* cmdApdu);
78 CommandApdu* cmdApdu);
/hardware/nxp/secure_element/1.0/
DSecureElement.cpp96 phNxpEse_data cmdApdu; in transmit() local
98 phNxpEse_memset(&cmdApdu, 0x00, sizeof(phNxpEse_data)); in transmit()
101 cmdApdu.len = data.size(); in transmit()
102 if (cmdApdu.len >= MIN_APDU_LENGTH) { in transmit()
103 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(data.size() * sizeof(uint8_t)); in transmit()
104 memcpy(cmdApdu.p_data, data.data(), cmdApdu.len); in transmit()
105 status = phNxpEse_Transceive(&cmdApdu, &rspApdu); in transmit()
116 phNxpEse_free(cmdApdu.p_data); in transmit()
141 phNxpEse_data cmdApdu; in openLogicalChannel() local
144 phNxpEse_memset(&cmdApdu, 0x00, sizeof(phNxpEse_data)); in openLogicalChannel()
[all …]
/hardware/st/secure_element/1.0/
DSecureElement.cpp114 StEse_data cmdApdu; in transmit() local
116 memset(&cmdApdu, 0x00, sizeof(StEse_data)); in transmit()
120 cmdApdu.len = data.size(); in transmit()
121 if (cmdApdu.len >= MIN_APDU_LENGTH) { in transmit()
122 cmdApdu.p_data = (uint8_t*)malloc(data.size() * sizeof(uint8_t)); in transmit()
123 memcpy(cmdApdu.p_data, data.data(), cmdApdu.len); in transmit()
125 if (aram_channel && (0x03 & cmdApdu.p_data[0]) == aram_channel && in transmit()
128 status = (ESESTATUS)Aram_transceive(&cmdApdu, &rspApdu); in transmit()
130 status = StEse_Transceive(&cmdApdu, &rspApdu); in transmit()
143 free(cmdApdu.p_data); in transmit()
[all …]
/hardware/nxp/secure_element/1.1/
DSecureElement.cpp137 phNxpEse_data cmdApdu; in transmit() local
139 phNxpEse_memset(&cmdApdu, 0x00, sizeof(phNxpEse_data)); in transmit()
142 cmdApdu.len = data.size(); in transmit()
143 if (cmdApdu.len >= MIN_APDU_LENGTH) { in transmit()
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()
146 status = phNxpEse_Transceive(&cmdApdu, &rspApdu); in transmit()
157 phNxpEse_free(cmdApdu.p_data); in transmit()
182 phNxpEse_data cmdApdu; in openLogicalChannel() local
185 phNxpEse_memset(&cmdApdu, 0x00, sizeof(phNxpEse_data)); in openLogicalChannel()
[all …]
/hardware/st/secure_element/1.1/
DSecureElement.cpp124 StEse_data cmdApdu; in transmit() local
126 memset(&cmdApdu, 0x00, sizeof(StEse_data)); in transmit()
130 cmdApdu.len = data.size(); in transmit()
131 if (cmdApdu.len >= MIN_APDU_LENGTH) { in transmit()
132 cmdApdu.p_data = (uint8_t*)malloc(data.size() * sizeof(uint8_t)); in transmit()
133 memcpy(cmdApdu.p_data, data.data(), cmdApdu.len); in transmit()
134 status = StEse_Transceive(&cmdApdu, &rspApdu); in transmit()
146 free(cmdApdu.p_data); in transmit()
174 StEse_data cmdApdu; in openLogicalChannel() local
177 memset(&cmdApdu, 0x00, sizeof(StEse_data)); in openLogicalChannel()
[all …]
/hardware/st/secure_element/1.2/
DSecureElement.cpp124 StEse_data cmdApdu; in transmit() local
126 memset(&cmdApdu, 0x00, sizeof(StEse_data)); in transmit()
130 cmdApdu.len = data.size(); in transmit()
131 if (cmdApdu.len >= MIN_APDU_LENGTH) { in transmit()
132 cmdApdu.p_data = (uint8_t*)malloc(data.size() * sizeof(uint8_t)); in transmit()
133 memcpy(cmdApdu.p_data, data.data(), cmdApdu.len); in transmit()
134 status = StEse_Transceive(&cmdApdu, &rspApdu); in transmit()
146 free(cmdApdu.p_data); in transmit()
174 StEse_data cmdApdu; in openLogicalChannel() local
177 memset(&cmdApdu, 0x00, sizeof(StEse_data)); in openLogicalChannel()
[all …]
/hardware/nxp/secure_element/ls_client/src/
DLsLib.cpp155 phNxpEse_data cmdApdu; in LSC_OpenChannel() local
157 phNxpEse_memset(&cmdApdu, 0x00, sizeof(phNxpEse_data)); in LSC_OpenChannel()
159 cmdApdu.len = (int32_t)sizeof(OpenChannel); in LSC_OpenChannel()
160 cmdApdu.p_data = (uint8_t*)phNxpEse_memalloc(cmdApdu.len * sizeof(uint8_t)); in LSC_OpenChannel()
161 memcpy(cmdApdu.p_data, OpenChannel, cmdApdu.len); in LSC_OpenChannel()
164 ESESTATUS eseStat = phNxpEse_Transceive(&cmdApdu, &rspApdu); in LSC_OpenChannel()
184 phNxpEse_free(cmdApdu.p_data); in LSC_OpenChannel()
210 phNxpEse_data cmdApdu; in LSC_ResetChannel() local
212 phNxpEse_memset(&cmdApdu, 0x00, sizeof(phNxpEse_data)); in LSC_ResetChannel()
214 cmdApdu.len = (int32_t)sizeof(OpenChannel); in LSC_ResetChannel()
[all …]