Daniele Antonioli, expert in Bluetooth security and the developer of BIAS, BLUR, and KNOB attack techniques, has discovered two new vulnerabilities (CVE-2023-24023) in the Bluetooth session negotiation mechanism, affecting all Bluetooth implementations that support the "Secure Connections" and "Secure Simple Pairing" secure pairing modes compliant with Bluetooth Core specifications 4.2-5.4. A demonstration of the practical application of the identified vulnerabilities has led to the development of 6 attack variants that allow an intrusion into the connection between previously paired Bluetooth devices. The code implementing the attack methods and the utility for checking the presence of vulnerabilities has been published on GitHub.
The vulnerabilities were identified during the analysis of mechanisms described in the standard for achieving forward and future secrecy, which counteract the compromise of session keys in the event of a permanent key being identified (the compromise of one of the permanent keys should not lead to the decryption of previously intercepted or future sessions) and the reuse of session keys (the key from one session should not be applicable to another session). The identified vulnerabilities allow bypassing the stated protection and reusing an insecure session key across different sessions. These vulnerabilities arise from shortcomings in the underlying standard, are not specific to individual Bluetooth stacks, and manifest in chips from various manufacturers.

The proposed attack methods implement different variants of spoofing classical (LSC, Legacy Secure Connections based on outdated cryptographic primitives) and secure (SC, Secure Connections based on ECDH and AES-CCM) Bluetooth connections between a system and a peripheral device, as well as MITM attack organization for connections in both LSC and SC modes. It is assumed that all Bluetooth implementations compliant with the standard are susceptible to various BLUFFS attack variants. The method's efficacy has been demonstrated on 18 devices from companies such as Intel, Broadcom, Apple, Google, Microsoft, CSR, Logitech, Infineon, Bose, Dell, and Xiaomi.

Podstata zranitelností spočívá v možnosti, bez porušení standardu, násilně přepnout připojení na používání starého režimu LSC a nespolehlivého krátkého sezení klíče (SK) tím, že se v průběhu vyjednávání připojení uvede minimálně možná entropie a ignoruje se obsah odpovědi s autentizačními parametry (CR), což vede k generaci sezení klíče na základě pevných vstupních parametrů (sezení klíč SK je počítán jako KDF z pevného klíče (PK) a dohodnutých během sezení parametrů). Například útočník během MITM útoku může v průběhu vyjednávání sezení nahradit parametry 𝐴𝐶 a 𝑆𝐷 nulovými hodnotami a nastavit entropii 𝑆𝐸 na 1, což povede k vytvoření sezení klíče 𝑆𝐾 s faktickou entropií 1 bajt (standardní minimální velikost entropie je 7 bajtů (56 bitů), což je z hlediska spolehlivosti srovnatelné s hrubým vyhledáváním klíčů DES).
Pokud se útočníkovi během vyjednávání připojení podaří dosáhnout použití kratšího klíče, může dále pomocí hrubé síly (brute force) určit pevný klíč (PK), který se používá k šifrování, a dosáhnout dešifrování provozu mezi zařízeními. Vzhledem k tomu, že během MITM útoku lze iniciovat použití stejného šifrovacího klíče, pokud bude tento klíč získán, lze ho využít i k dešifrování všech minulých a budoucích sezení, která byla útočníkem zachycena.

Pro blokování zranitelností navrhl výzkumník provést v normě změny, které rozšiřují protokol LMP a mění logiku používání KDF (Key Derivation Function) při tvorbě klíčů v režimu LSC. Změna nenarušuje zpětnou kompatibilitu, ale vede k zapracování rozšířené LMP příkazu a nutnosti odeslat dalších 48 bajtů. Organizace Bluetooth SIG, odpovědná za vývoj Bluetooth standardů, jako ochranné opatření navrhla odmítat připojení přes šifrovaný komunikační kanál s klíči o velikosti do 7 bajtů. Implementacím, které vždy používají úroveň Security Mode 4 Level 4, se doporučuje odmítat připojení s klíči o velikosti do 16 bajtů.
Zdroj: opennet.ru
