Home
last modified time | relevance | path

Searched refs:prand (Results 1 – 4 of 4) sorted by relevance

/system/bt/gd/hci/
Daddress_with_type.h57 uint8_t prand[3]; in IsRpaThatMatchesIrk() local
58 prand[0] = address_.address[2]; in IsRpaThatMatchesIrk()
59 prand[1] = address_.address[1]; in IsRpaThatMatchesIrk()
60 prand[2] = address_.address[0]; in IsRpaThatMatchesIrk()
62 crypto_toolbox::Octet16 computed_hash = crypto_toolbox::aes_128(irk, &prand[0], 3); in IsRpaThatMatchesIrk()
Dle_address_manager.cc249 std::array<uint8_t, 3> prand = os::GenerateRandom<3>(); in generate_rpa() local
251 prand[2] &= ~BLE_ADDR_MASK; in generate_rpa()
252 if ((prand[0] == 0x00 && prand[1] == 0x00 && prand[2] == 0x00) || in generate_rpa()
253 (prand[0] == 0xFF && prand[1] == 0xFF && prand[2] == 0x3F)) { in generate_rpa()
254 prand[0] = (uint8_t)(os::GenerateRandom() % 0xFE + 1); in generate_rpa()
256 prand[2] |= BLE_RESOLVE_ADDR_MSB; in generate_rpa()
259 address.address[3] = prand[0]; in generate_rpa()
260 address.address[4] = prand[1]; in generate_rpa()
261 address.address[5] = prand[2]; in generate_rpa()
264 crypto_toolbox::Octet16 p = crypto_toolbox::aes_128(rotation_irk_, prand.data(), 3); in generate_rpa()
/system/bt/stack/test/
Dcrypto_toolbox_test.cc299 Octet16 prand{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, in TEST() local
307 std::reverse(std::begin(prand), std::end(prand)); in TEST()
311 Octet16 result = aes_128(IRK, prand.data(), 3); in TEST()
/system/bt/gd/crypto_toolbox/
Dcrypto_toolbox_test.cc263 …Octet16 prand{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, … in TEST() local
270 std::reverse(std::begin(prand), std::end(prand)); in TEST()
274 Octet16 result = aes_128(IRK, prand.data(), 3); in TEST()