Home
last modified time | relevance | path

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

/external/libese/libapdu/tests/
Dapdu_test.cpp31 const CommandApdu apdu{1, 2, 3, 4}; in TEST() local
33 ASSERT_EQ(expected.size(), apdu.size()); in TEST()
34 ASSERT_TRUE(std::equal(apdu.begin(), apdu.end(), expected.begin(), expected.end())); in TEST()
38 const CommandApdu apdu{4, 3, 2, 1, 0, 3}; in TEST() local
40 ASSERT_EQ(expected.size(), apdu.size()); in TEST()
41 ASSERT_TRUE(std::equal(apdu.begin(), apdu.end(), expected.begin(), expected.end())); in TEST()
45 const CommandApdu apdu{4, 3, 2, 1, 0, 256}; in TEST() local
47 ASSERT_EQ(expected.size(), apdu.size()); in TEST()
48 ASSERT_TRUE(std::equal(apdu.begin(), apdu.end(), expected.begin(), expected.end())); in TEST()
52 const CommandApdu apdu{5, 6, 7, 8, 0, 258}; in TEST() local
[all …]
/external/libese/apps/weaver/card/src/com/android/weaver/
DWeaver.java71 public void process(APDU apdu) { in process() argument
87 final byte buffer[] = apdu.getBuffer(); in process()
92 if (apdu.isISOInterindustryCLA()) { in process()
105 getNumSlots(apdu); in process()
109 write(apdu); in process()
113 read(apdu); in process()
117 eraseValue(apdu); in process()
121 eraseAll(apdu); in process()
136 private void getNumSlots(APDU apdu) { in getNumSlots() argument
137 p1p2Unused(apdu); in getNumSlots()
[all …]
/external/libese/apps/boot/card/src/com/android/verifiedboot/storage/
DStorage.java40 import javacardx.apdu.ExtendedLength;
230 private short sendStorageState(APDU apdu) { in sendStorageState() argument
231 final byte buffer[] = apdu.getBuffer(); in sendStorageState()
236 short expectedLength = apdu.setOutgoing(); in sendStorageState()
245 apdu.setOutgoingLength((short) 4); in sendStorageState()
246 apdu.sendBytes((short) 0, (short) 4); in sendStorageState()
250 apdu.setOutgoingLength(length); in sendStorageState()
258 apdu.sendBytesLong(working, (short) 0, (short) 2); in sendStorageState()
266 apdu.sendBytesLong(working, (short) 0, (short) 1); in sendStorageState()
274 apdu.sendBytesLong(working, (short) 0, (short) 2); in sendStorageState()
[all …]
/external/libese/esed/
Dutils.h107 ResponseApdu apdu{responseBuffer};
108 if (!apdu.ok()) {
115 return handler(apdu);
126 T checkLength(const ResponseApdu& apdu, const size_t size) { in checkLength() argument
127 if (apdu.dataSize() != size) { in checkLength()
139 T checkNoErrorAndLength(const ResponseApdu& apdu, const size_t size) { in checkNoErrorAndLength() argument
140 if (apdu.isError()) { in checkNoErrorAndLength()
144 return checkLength<T, OK, FAILED>(apdu, size); in checkNoErrorAndLength()
/external/libese/examples/
Dese_nxp_sample.c101 const struct Apdu *apdu = kSessions[s]->apdus[apdu_index]; in main() local
102 printf("Sending APDU %u: %s\n", apdu_index, apdu->desc); in main()
103 printf("Sending %u bytes to card\n", apdu->length); in main()
105 for (i = 0; i < apdu->length; ++i) in main()
106 printf("%.2X ", apdu->bytes[i]); in main()
109 recvd = ese_transceive(&ese, (uint8_t *)apdu->bytes, apdu->length, rx_buf, in main()
/external/libese/libese-hw/tests/
Dese_hw_echo_tests.cpp43 std::vector<uint8_t> apdu; in TEST_F() local
46 apdu.resize(apdu_len, 'A'); in TEST_F()
48 …EXPECT_EQ(apdu_len, ese_transceive(&ese_, apdu.data(), apdu_len, apdu_reply.data(), apdu_reply.siz… in TEST_F()
50 EXPECT_EQ(apdu, apdu_reply); in TEST_F()
/external/libese/apps/weaver/card/src/com/android/weaver/core/
DWeaverCore.java66 public void process(APDU apdu) { in process() argument
/external/libese/libapdu/
DAndroid.bp34 "apdu.cpp",