Home
last modified time | relevance | path

Searched refs:Octet16 (Results 1 – 25 of 106) sorted by relevance

12345

/packages/modules/Bluetooth/system/gd/crypto_toolbox/
Dcrypto_toolbox.h27 bluetooth::hci::Octet16 c1(
28 const bluetooth::hci::Octet16& k,
29 const bluetooth::hci::Octet16& r,
36 bluetooth::hci::Octet16 s1(
37 const bluetooth::hci::Octet16& k,
38 const bluetooth::hci::Octet16& r1,
39 const bluetooth::hci::Octet16& r2);
41 bluetooth::hci::Octet16 aes_128(
42 const bluetooth::hci::Octet16& key, const bluetooth::hci::Octet16& message);
43 bluetooth::hci::Octet16 aes_cmac(
[all …]
Dcrypto_toolbox_test.cc31 using bluetooth::hci::Octet16;
57Octet16 k{0x2b, 0x7e, 0x15, 0x16, 0x28, 0xae, 0xd2, 0xa6, 0xab, 0xf7, 0x15, 0x88, 0x09, 0xcf, 0x4f… in TEST()
59Octet16 aes_cmac_k_m{0xbb, 0x1d, 0x69, 0x29, 0xe9, 0x59, 0x37, 0x28, 0x7f, 0xa3, 0x7d, 0x12, 0x9b,… in TEST()
65 Octet16 output = aes_cmac(k, nullptr /* empty message */, 0); in TEST()
76Octet16 k{0x2b, 0x7e, 0x15, 0x16, 0x28, 0xae, 0xd2, 0xa6, 0xab, 0xf7, 0x15, 0x88, 0x09, 0xcf, 0x4f… in TEST()
78Octet16 m = {0x6b, 0xc1, 0xbe, 0xe2, 0x2e, 0x40, 0x9f, 0x96, 0xe9, 0x3d, 0x7e, 0x11, 0x73, 0x93, 0… in TEST()
80Octet16 aes_cmac_k_m{0x07, 0x0a, 0x16, 0xb4, 0x6b, 0x4d, 0x41, 0x44, 0xf7, 0x9b, 0xdd, 0x9d, 0xd0,… in TEST()
87 Octet16 output = aes_cmac(k, m); in TEST()
99Octet16 k{0x2b, 0x7e, 0x15, 0x16, 0x28, 0xae, 0xd2, 0xa6, 0xab, 0xf7, 0x15, 0x88, 0x09, 0xcf, 0x4f… in TEST()
105Octet16 aes_cmac_k_m{0xdf, 0xa6, 0x67, 0x47, 0xde, 0x9a, 0xe6, 0x30, 0x30, 0xca, 0x32, 0x61, 0x14,… in TEST()
[all …]
Dcrypto_toolbox.cc28 using bluetooth::hci::Octet16;
32 Octet16 h6(const Octet16& w, std::array<uint8_t, 4> keyid) { in h6()
36 Octet16 h7(const Octet16& salt, const Octet16& w) { in h7()
40 Octet16 f4(const uint8_t* u, const uint8_t* v, const Octet16& x, uint8_t z) { in f4()
58 static Octet16 calculate_mac_key_or_ltk( in calculate_mac_key_or_ltk()
59 const Octet16& t, in calculate_mac_key_or_ltk()
62 const Octet16& n1, in calculate_mac_key_or_ltk()
63 const Octet16& n2, in calculate_mac_key_or_ltk()
86 const Octet16& n1, in f5()
87 const Octet16& n2, in f5()
[all …]
Daes_cmac.cc35 using bluetooth::hci::Octet16;
50 Octet16 const_Rb{0x87, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00…
55 static void xor_128(Octet16* a, const Octet16& b) { in xor_128()
66 Octet16 aes_128(const Octet16& key, const Octet16& message) { in aes_128()
67 Octet16 key_reversed; in aes_128()
68 Octet16 message_reversed; in aes_128()
69 Octet16 output; in aes_128()
85 static void padding(Octet16* dest, uint8_t length) { in padding()
104 static Octet16 cmac_aes_k_calculate(const Octet16& key) { in cmac_aes_k_calculate()
105 Octet16 output; in cmac_aes_k_calculate()
[all …]
/packages/modules/Bluetooth/system/gd/security/
Dinitial_informations.h38 std::optional<hci::Octet16> remote_ltk;
42 std::optional<hci::Octet16> remote_irk;
43 std::optional<hci::Octet16> remote_signature_key;
44 std::optional<hci::Octet16> remote_link_key; /* BR/EDR Keys */
46 std::optional<hci::Octet16> local_ltk;
49 std::optional<hci::Octet16> local_signature_key;
69 hci::Octet16 c;
70 hci::Octet16 r;
79 hci::Octet16 my_identity_resolving_key;
101 hci::Octet16 le_sc_c; /* LE Secure Connections Confirmation Value */
[all …]
Dpairing_handler_le_legacy.cc30 using hci::Octet16;
75 return Octet16{0}; in LegacyJustWorks()
114 Octet16 tk{0}; in LegacyPasskeyEntry()
129 … const PairingResponseView& pairing_response, const Octet16& tk) { in DoLegacyStage2()
134 Octet16 mrand, srand; in DoLegacyStage2()
143 Octet16 mconfirm = crypto_toolbox::c1( in DoLegacyStage2()
164 Octet16 sconfirm = std::get<PairingConfirmView>(sconfirm_pkt).GetConfirmValue(); in DoLegacyStage2()
178 Octet16 sconfirm_generated = crypto_toolbox::c1( in DoLegacyStage2()
200 Octet16 sconfirm = crypto_toolbox::c1( in DoLegacyStage2()
215 Octet16 mconfirm = std::get<PairingConfirmView>(mconfirm_pkt).GetConfirmValue(); in DoLegacyStage2()
[all …]
Dpairing_handler_le.cc29 using hci::Octet16;
129 Octet16 ltk = std::get<Octet16>(stage_2_result); in PairingMain()
151 Octet16 tk = std::get<Octet16>(stage1result); in PairingMain()
159 Octet16 stk = std::get<Octet16>(stage2result); in PairingMain()
208 Octet16 link_key = crypto_toolbox::ltk_to_link_key(*(distributed_keys.remote_ltk), use_h7); in PairingMain()
348 Octet16 my_ltk = bluetooth::os::GenerateRandom<16>(); in DistributeKeys()
352 Octet16 my_irk = i.my_identity_resolving_key; in DistributeKeys()
356 Octet16 my_signature_key{0}; in DistributeKeys()
391 std::optional<Octet16> ltk; /* Legacy only */ in ReceiveKeys()
395 std::optional<Octet16> irk; in ReceiveKeys()
[all …]
Dpairing_handler_le_secure_connections.cc30 using hci::Octet16;
164 Octet16 ltk, mac_key; in DoSecureConnectionsStage2()
185 Octet16 Ea = crypto_toolbox::f6(mac_key, Na, Nb, rb, iocapA.data(), a, b); in DoSecureConnectionsStage2()
187 Octet16 Eb = crypto_toolbox::f6(mac_key, Nb, Na, ra, iocapB.data(), b, a); in DoSecureConnectionsStage2()
229 Octet16 zeros{0}; in SecureConnectionsOutOfBand()
230Octet16 localR = (remote_oob_flag == OobDataFlag::PRESENT && i.my_oob_data) ? i.my_oob_data->r : z… in SecureConnectionsOutOfBand()
231 Octet16 remoteR; in SecureConnectionsOutOfBand()
239 Octet16 remoteC = i.remote_oob_data->le_sc_c; in SecureConnectionsOutOfBand()
241 Octet16 remoteC2; in SecureConnectionsOutOfBand()
254 Octet16 Na, Nb, ra, rb; in SecureConnectionsOutOfBand()
[all …]
Dpairing_handler_le.h86 using Stage1Result = std::tuple<hci::Octet16, hci::Octet16, hci::Octet16, hci::Octet16>;
88 using Stage2ResultOrFailure = std::variant<PairingFailure, hci::Octet16 /* LTK */>;
91 using LegacyStage1Result = hci::Octet16 /*TK*/;
93 using StkOrFailure = std::variant<PairingFailure, hci::Octet16 /* STK */>;
137 const hci::Octet16& ltk) { in SendHciLeStartEncryption()
149 const InitialInformations& i, uint16_t conn_handle, const hci::Octet16& ltk) { in SendHciLeLongTermKeyReply()
255 const hci::Octet16& tk);
260 hci::Octet16 ltk,
263 hci::Octet16 irk,
266 hci::Octet16 signature_key);
/packages/modules/Bluetooth/system/stack/include/
Dbtm_ble_sec_api_types.h30 Octet16 ltk;
40 Octet16 csrk;
46 Octet16 ltk;
57 Octet16 csrk;
61 Octet16 irk;
105 Octet16 ir;
106 Octet16 irk;
107 Octet16 dhk;
113 Octet16 er;
Dbt_octets.h23 using Octet16 = bluetooth::hci::Octet16; variable
24 using LinkKey = bluetooth::hci::Octet16; /* Link Key */
29 constexpr Octet16 SAMPLE_LTK = {0xbf, 0x01, 0xfb, 0x9d, 0x4e, 0xf3, 0xbc, 0x36,
31 inline bool is_sample_ltk(const Octet16& ltk) { return ltk == SAMPLE_LTK; } in is_sample_ltk()
Dbtm_ble_sec_api.h65 const Octet16& BTM_GetDeviceEncRoot();
68 const Octet16& BTM_GetDeviceIDRoot();
71 const Octet16& BTM_GetDeviceDHK();
221 std::optional<Octet16> BTM_BleGetPeerLTK(const RawAddress address);
237 std::optional<Octet16> BTM_BleGetPeerIRK(const RawAddress address);
/packages/modules/Bluetooth/tools/rootcanal/include/crypto/
Dcrypto.h26 using Octet16 = std::array<uint8_t, kOctet16Length>; variable
28 Octet16 aes_128(const Octet16& key, const Octet16& message);
33 inline Octet16 aes_128(const Octet16& key, const uint8_t* message, in aes_128()
35 Octet16 padded_message{0}; in aes_128()
/packages/modules/Bluetooth/system/stack/smp/
Dsmp_keys.cc59 static void smp_process_stk(tSMP_CB* p_cb, Octet16* p);
60 static Octet16 smp_calculate_legacy_short_term_key(tSMP_CB* p_cb);
90 inline void smp_debug_print_nbyte_little_endian(const Octet16& p, in smp_debug_print_nbyte_little_endian()
164 Octet16 output; in smp_generate_stk()
182 Octet16 buffer{}; /* for (r || DIV) r=1*/ in smp_compute_csrk()
189 const Octet16& er = BTM_GetDeviceEncRoot(); in smp_compute_csrk()
263 Octet16 smp_gen_p1_4_confirm(tSMP_CB* p_cb, in smp_gen_p1_4_confirm()
267 Octet16 p1; in smp_gen_p1_4_confirm()
299 Octet16 smp_gen_p2_4_confirm(tSMP_CB* p_cb, const RawAddress& remote_bda) { in smp_gen_p2_4_confirm()
301 Octet16 p2{0}; in smp_gen_p2_4_confirm()
[all …]
Dsmp_int.h299 Octet16 confirm;
300 Octet16 rconfirm;
301 Octet16 rrand; /* for SC this is peer nonce */
302 Octet16 rand; /* for SC this is local nonce */
305 Octet16 commitment;
306 Octet16 remote_commitment;
307 Octet16 local_random; /* local randomizer - passkey or OOB randomizer */
308 Octet16 peer_random; /* peer randomizer - passkey or OOB randomizer */
309 Octet16 dhkey_check;
310 Octet16 remote_dhkey_check;
[all …]
/packages/modules/Bluetooth/tools/rootcanal/lib/crypto/
Dcrypto.cc26 Octet16 aes_128(const Octet16& key, const Octet16& message) { in aes_128()
27 Octet16 key_reversed; in aes_128()
28 Octet16 message_reversed; in aes_128()
29 Octet16 output; in aes_128()
/packages/modules/Bluetooth/system/stack/test/
Dstack_smp_test.cc136 Octet16 smp_gen_p1_4_confirm(tSMP_CB* p_cb, tBLE_ADDR_TYPE remote_bd_addr_type);
138 Octet16 smp_gen_p2_4_confirm(tSMP_CB* p_cb, const RawAddress& remote_bda);
140 tSMP_STATUS smp_calculate_comfirm(tSMP_CB* p_cb, const Octet16& rand,
141 Octet16* output);
143 void dump_uint128(const Octet16& a, char* buffer) { in dump_uint128()
151 void dump_uint128_reverse(const Octet16& a, char* buffer) { in dump_uint128_reverse()
159 void print_uint128(const Octet16& a) { in print_uint128()
166 Octet16 parse_uint128(const char* input) { in parse_uint128()
167 Octet16 output{0}; in parse_uint128()
179 Octet16 rand_{0x57, 0x83, 0xD5, 0x21, 0x56, 0xAD, 0x6F, 0x0E,
[all …]
/packages/modules/Bluetooth/system/test/mock/
Dmock_stack_btm_ble.h251 static const Octet16 return_value;
252 std::function<const Octet16&()> body{
254 []() -> const Octet16& { return return_value; }};
255 const Octet16& operator()() { return body(); }; in operator()
263 static const Octet16 return_value;
264 std::function<const Octet16&()> body{
266 []() -> const Octet16& { return return_value; }};
267 const Octet16& operator()() { return body(); }; in operator()
275 static const Octet16 return_value;
276 std::function<const Octet16&()> body{
[all …]
Dmock_btif_storage.h137 std::function<bt_status_t(const Octet16& key_value, uint8_t key_type)> body{
138 [](const Octet16& /* key_value */, uint8_t /* key_type */) {
141 bt_status_t operator()(const Octet16& key_value, uint8_t key_type) { in operator()
231 std::function<bt_status_t(uint8_t key_type, Octet16* key_value)> body{
232 [](uint8_t /* key_type */, Octet16* /* key_value */) {
235 bt_status_t operator()(uint8_t key_type, Octet16* key_value) { in operator()
245 static Octet16 return_value;
246 std::function<Octet16(const RawAddress& bd_addr)> body{
248 Octet16 operator()(const RawAddress& bd_addr) { return body(bd_addr); }; in operator()
470 std::function<void(const RawAddress& bd_addr, Octet16 hash)> body{
[all …]
Dmock_btif_dm.cc110 Octet16* /* p_er */, in btif_dm_get_ble_local_keys() argument
170 bool btif_dm_proc_rmt_oob(const RawAddress& /* bd_addr */, Octet16* /* p_c */, in btif_dm_proc_rmt_oob() argument
171 Octet16* /* p_r */) { in btif_dm_proc_rmt_oob()
177 const Octet16& /* c */, const Octet16& /* r */) { in btif_dm_proc_loc_oob() argument
Dmock_stack_btm_ble.cc102 const Octet16 BTM_GetDeviceDHK::return_value{0xd5, 0xcb, 0x84, 0x54, 0xd1, 0x77,
105 const Octet16 BTM_GetDeviceEncRoot::return_value{
108 const Octet16 BTM_GetDeviceIDRoot::return_value{
200 const Octet16& BTM_GetDeviceDHK() { in BTM_GetDeviceDHK()
204 const Octet16& BTM_GetDeviceEncRoot() { in BTM_GetDeviceEncRoot()
208 const Octet16& BTM_GetDeviceIDRoot() { in BTM_GetDeviceIDRoot()
288 const Octet16& stk) { in btm_ble_ltk_request_reply()
326 Octet16* p_stk) { in btm_ble_start_encrypt()
375 std::optional<Octet16> BTM_BleGetPeerLTK(const RawAddress /* address */) { in BTM_BleGetPeerLTK()
/packages/modules/Bluetooth/system/btif/include/
Dbtif_dm.h96 const Octet16& c, const Octet16& r);
97 bool btif_dm_proc_rmt_oob(const RawAddress& bd_addr, Octet16* p_c,
98 Octet16* p_r);
148 Octet16* p_er,
/packages/modules/Bluetooth/system/bta/include/
Dbta_sec_api.h123 Octet16 ir;
124 Octet16 irk;
125 Octet16 dhk;
226 Octet16 local_oob_c; /* Local OOB Data Confirmation/Commitment */
227 Octet16 local_oob_r; /* Local OOB Data Randomizer */
243 Octet16 ble_er; /* ER event data */
/packages/modules/Bluetooth/system/gd/security/record/
Dsecurity_record.h124 std::optional<hci::Octet16> remote_ltk;
129 std::optional<hci::Octet16> remote_irk;
130 std::optional<hci::Octet16> remote_signature_key;
132 std::optional<hci::Octet16> local_ltk;
/packages/modules/Bluetooth/system/gd/hci/
Dle_address_manager_test.cc28 using ::bluetooth::hci::Octet16;
134Octet16 irk = {0xec, 0x02, 0x34, 0xa3, 0x57, 0xc8, 0xad, 0x05, 0x34, 0x10, 0x10, 0xa6, 0x0a, 0x39,… in TEST_F()
156 Octet16 irk = {}; in TEST_F()
180Octet16 irk = {0xec, 0x02, 0x34, 0xa3, 0x57, 0xc8, 0xad, 0x05, 0x34, 0x10, 0x10, 0xa6, 0x0a, 0x39,… in TEST_F()
218Octet16 irk = {0xec, 0x02, 0x34, 0xa3, 0x57, 0xc8, 0xad, 0x05, 0x34, 0x10, 0x10, 0xa6, 0x0a, 0x39,… in SetUp()
309Octet16 peer_irk = {0xec, 0x02, 0x34, 0xa3, 0x57, 0xc8, 0xad, 0x05, 0x34, 0x10, 0x10, 0xa6, 0x0a, … in TEST_F()
310Octet16 local_irk = {0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d,… in TEST_F()
348Octet16 peer_irk = {0xec, 0x02, 0x34, 0xa3, 0x57, 0xc8, 0xad, 0x05, 0x34, 0x10, 0x10, 0xa6, 0x0a, … in TEST_F()
349 Octet16 local_irk = { in TEST_F()
411Octet16 peer_irk = {0xec, 0x02, 0x34, 0xa3, 0x57, 0xc8, 0xad, 0x05, 0x34, 0x10, 0x10, 0xa6, 0x0a, … in TEST_F()
[all …]

12345