Commit f45f668
host/sm: Reject Legacy pairing confirm reflection attack
When the responder mirrors the initiator's confirm and random
values (Sconfirm=Mconfirm, Srand=Mrand), the c1 check passes
trivially, bypassing mismatch detection and causing an HCI
encryption failure (0x06) instead of Pairing Failed (0x04).
Detect Srand==Mrand in ble_sm_lgcy_random_rx and abort
with LE_SM_ERR_CONFIRM_MISMATCH.
Fixes SM/CEN/JW/BI-06-C and SM/CEN/PKE/BI-03-C1 parent bd6d94c commit f45f668
1 file changed
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
215 | 215 | | |
216 | 216 | | |
217 | 217 | | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
218 | 230 | | |
219 | 231 | | |
220 | 232 | | |
| |||
0 commit comments