1

I want to store information about BLE device locally, but I cannot rely on MAC address because it changes too often. Is there any way to do that?

darkchaos
  • 197
  • 1
  • 11
  • It depends on your device. BLE has 3 types of MAC: real, public random and private random (they may have other names in docs). The real one (public) is the real device's MAC that is permanent. Public random is the random MAC address but it can be converted to real MAC if you know encryption key. And the private MAC can not be converted to real. In first 2 cases you can identify your device even if random changed each time. In third case there is no way to identify the device. Here you can find more information: http://microchipdeveloper.com/wireless:ble-link-layer-address – Mike Petrichenko Jan 17 '19 at 17:27

1 Answers1

1

The Bluetooth address is the best way you can distinguish between devices. This is mentioned in the Bluetooth specification as follows [1]:

Devices are identified using a device address. Device addresses may be either a public device address or a random device address. A public device address and a random device address are both 48 bits in length

As Mike mentioned, there are a few types of MAC Addresses and the one that is changing is not the one that you want to look at. The Bluetooth specification identifies the following addresses:-

  • Public Address: This is a unique address created in accordance with IEEE 802-2014 Standard. For you this is the Address relevant to your answer.
  • Random Static Address: This is a randomly generated address that does not change unless the device is power cycled. Therefore, if your device is not power cycled you can use this address to identify it.
  • Private Resolvable Address: This is a changing MAC address (with the frequency of the change depending on the application) that can be resolved and associated with the device's unique address if the IRK is known (i.e. if the devices are paired).
  • Private Non-resolvable Address: This is a changing MAC address (with the frequency of the change depending on the application) that cannot be resolved nor associated with the device's unique address. This kind of address is usually used for security reasons when a device only advertises.

For more information, please see the reference below.

I hope this helps.

[1] Bluetooth Core Specification Version 5.0, Vol 6, Part B, Section 1.3 DEVICE ADDRESS.

Youssif Saeed
  • 11,789
  • 4
  • 44
  • 72