MAC Address Rotation Test Cases
This section covers test cases for verifying BLE MAC address rotation behavior on Sidewalk Endpoints. MAC address rotation is a privacy mechanism that ensures the BLE beacon MAC address changes on specific events and at regular intervals.
Test Case BLE/EP/BCN/MAC/BV/01: Verify MAC address rotation after registration
| Field | Value |
|---|---|
| Case ID | C103619309 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack and collect MAC address in beacon:sid init 1sid start | CMD: ERR: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_1> |
| 2 | Wait for EN to register and collect MAC address again | EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 1BT sniffer captures BLE beacon with MAC address: <mac_addr_2> |
| 3 | Check MAC address rotation | mac_addr_1 != mac_addr_2 |
Key check: MAC address rotated after registration (Reg: 0 confirms registered state)
Test Case BLE/EP/BCN/MAC/BV/02: Verify MAC address rotation after time sync
| Field | Value |
|---|---|
| Case ID | C103619310 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack and collect MAC address before time sync:sid init 1sid start | CMD: ERR: 0EVENT SID STATUS: State: 0, Reg: 0, Time: 1, Link_Mask: 1BT sniffer captures BLE beacon with MAC address: <mac_addr_1>Key check: EN registered (Reg: 0), time not yet synced (Time: 1) |
| 2 | Wait for time sync, wait for BLE disconnected, then collect MAC address again | EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 1EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_2> |
| 3 | Check MAC address rotation | mac_addr_1 != mac_addr_2 |
Key check: MAC address rotated after time sync (Time: 0 confirms synced state)
Test Case BLE/EP/BCN/MAC/BV/03: Verify MAC address rotates every 15 minutes
| Field | Value |
|---|---|
| Case ID | C103619311 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack, wait for time sync, wait another 30s to confirm BLE disconnected:sid init 1sid start | CMD: ERR: 0EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0Key check: Time synced (Time: 0), BLE disconnected |
| 2 | Monitor 2 MAC address rotations (check every 30s, expect rotation ~15 min) | Round 1: MAC rotated after ~900s (<mac_addr_1> -> <mac_addr_2>)Round 2: MAC rotated after ~900s ( <mac_addr_2> -> <mac_addr_3>) |
| 3 | Check MAC address rotation interval | All 3 MAC addresses are unique |
Key check: Each rotation interval is between 840s~960s (14~16 min). MAC rotates every ~15 minutes.
Test Case BLE/EP/BCN/MAC/BV/04: Verify MAC address rotation after connection request sent to cloud
| Field | Value |
|---|---|
| Case ID | C103619312 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack, wait for time sync, wait another 30s to confirm BLE disconnected, collect MAC address:sid init 1sid start | CMD: ERR: 0EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_1> |
| 2 | Establish BLE connection and collect MAC address:sid conn_req 1 | CMD: ERR: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 1BT sniffer captures BLE beacon with MAC address: <mac_addr_2>Key check: BLE connection established (BLE: 1) |
| 3 | Check MAC address rotation | mac_addr_1 != mac_addr_2 |
Key check: MAC address rotated after connection request
Test Case BLE/EP/BCN/MAC/BV/05: Verify MAC address rotation on disconnection from Sidewalk cloud
| Field | Value |
|---|---|
| Case ID | C103619313 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack, wait for time sync, wait for BLE disconnected, collect MAC address:sid init 1sid start | CMD: ERR: 0EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_1> |
| 2 | Establish BLE connection:sid conn_req 1 | CMD: ERR: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 1BT sniffer captures BLE beacon with MAC address: <mac_addr_2>Key check: BLE connection established (BLE: 1), MAC rotated on connection |
| 3 | Wait for BLE to disconnect, collect MAC address | EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_3> |
| 4 | Check MAC address rotation after disconnection | mac_addr_2 != mac_addr_3 |
Key check: MAC address rotated after disconnection from Sidewalk cloud
Test Case BLE/EP/BCN/MAC/BV/06: Verify MAC address rotation on downlink reception
| Field | Value |
|---|---|
| Case ID | C103619314 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack, wait for time sync, wait for BLE disconnected, collect MAC address:sid init 1sid start | CMD: ERR: 0EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_1> |
| 2 | Send DL from AWS IoT | EVENT SID RECEIVED: TYPE: 2, ID: <id>, LEN: <len>, LINK: 1, LINK_MODE: 1, ACK_REQUESTED: 0, ACK: 0, DUP: 0, RSSI: <rssi>, SNR: <snr>Key check: DL received through BLE (LINK: 1) |
| 3 | Wait for BLE to disconnect, collect MAC address | EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_2> |
| 4 | Check MAC address rotation | mac_addr_1 != mac_addr_2 |
Key check: MAC address rotated after downlink reception
Test Case BLE/EP/BCN/MAC/BV/07: Verify MAC address rotation on key refresh
| Field | Value |
|---|---|
| Case ID | C103619315 |
| Executable by Customer | No |
Preconditions
- Nordic-based BT sniffer connected to PC
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Setup Nordic-based BT sniffer, connect it to PC and start sniffing packets | Sniffer gives possibility to capture BT traffic (beacons) including MAC address sent over the air |
| 2 | Trigger key refresh | BLE connection is established and key refresh is completed |
| 3 | Wait until BLE connection is disconnected | MAC address has rotated and is different than in previous step |
Key check: MAC address rotated after key refresh event
Test Case BLE/EP/BCN/MAC/BV/08: Verify MAC address rotation on long lived connection
| Field | Value |
|---|---|
| Case ID | C103619316 |
| Executable by Customer | Yes |
Preconditions
- BT sniffer is ready to capture BLE beacons
Test Steps
| Step | Description | Expected Result |
|---|---|---|
| 1 | Initialize BLE stack, wait for time sync, wait for BLE disconnected, collect MAC address:sid init 1sid start | CMD: ERR: 0EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_1> |
| 2 | Set long lived connection policy:ble_policy 1 1 1 | CMD: ERR: 0BLE conn policy 1Key check: Long lived policy set |
| 3 | Establish BLE connection:sid conn_req 1 | CMD: ERR: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 1Key check: BLE connection established (BLE: 1) |
| 4 | Wait 15 minutes and verify BLE is still connected | EVENT SID STATUS: State: 0, Reg: 0, Time: 0, Link_Mask: 1Key check: BLE still connected after 15 min (Link_Mask: 1) |
| 5 | Set default policy and wait for BLE to disconnect, collect MAC address:ble_policy 1 0 | CMD: ERR: 0EVENT SID STATUS LINK MODE: LORA: 0, FSK: 0, BLE: 0BT sniffer captures BLE beacon with MAC address: <mac_addr_2> |
| 6 | Check MAC address rotation | mac_addr_1 != mac_addr_2 |
Key check: MAC address rotated after long lived connection ended