Bluetooth Low Energy Security: Keys, Modes & Bluetooth 4.2

Publié par

Bluetooth Low Energy was designed with an AES-128 encryption for security. While AES-128 is one of the most robust encryption schemes, it’s important to understand how keys are exchanged to really evaluate the true level of security.

BLE has five main keys:

• Temporary Key
• Short-Term Key
• Long-Term Key
• Identity Resolving Key
• Connection Signature Key

Security Keys: Bluetooth Pairing, Encryption & Authentication

The temporary key is used during the Bluetooth pairing process. The short term key is used as the key for encrypting a connection the very first time devices pair. The short term key is generated by using three pieces of information: the Temporary Key, and two random numbers, one generated by the slave and one generated by the master.

Once the connection is encrypted with the short term key, the other keys are distributed.  The Long Term Key replaces the short term key to encrypt the connection. The Identity Resolving Key is used for privacy. The Connection Signature Key is used for authentication.

With all this, can you be sure nobody can eavesdrop on the communication? In fact, with Bluetooth 4.0 and 4.1, a weakness exists at the temporary key generation. Encryption is like a chain -- it is as strong as the weakest link.

In Bluetooth 4.0 and 4.1, three options are specified for the short-term key:
• Just Works
• Passkey Entry
• Out of Band.

Bluetooth Pairing Modes: Just Works, Passkey Entry & OOB

“Just Works” is a mode designed to make the connection to Bluetooth Low Energy devices possible when very limited user interfaces prevent user entry or verification of pass key values. The temporary in this situation is zero. It is obvious this scenario is vulnerable to attacks.

The mode “Passkey Entry” is used when the user interfaces on both devices allow at least the display or entry of a number value. This value can take any integer between 0 and 999999. This number is not complex enough to withstand brute force attack. 

Voir les produits connexes

2267

Adafruit Industries Cartes et kits de développement RF/sans fil Afficher

The last mode is the “Out Of Band” algorithm when the Temporary Key has been shared by using another technology than Bluetooth. NFC technology is the common one and is considered as secure. Bottom line, among the three modes to share the Temporary Key, only one can be considered as secure against eavesdropping.

Bluetooth 4.2 Low Energy

Bluetooth Low Energy 4.2 resolved this problem by implementing the Diffie-Hellman scheme. As often in encryption, this protocol is based on simple mathematics that is difficult to solve. Prime numbers are often the base of encryption protocols. 

If p is a large prime number, g an integer in {1,…,p} and x a chosen randomly in {1,…, p-1}, knowing the result , there is no known efficient algorithm to calculate x. Then, with two numbers x and y, it is very easy to perform exponential operation to end up with a key, but very hard to reverse the operation to discover the key.

If Alice and Bob want to share the key and there is an eavesdropper between them, the following steps are performed to share the key:

0316 Security for BLE In Article 1 V2

Several Diffie-Hellman variants exist. In Bluetooth 4.2, the Elliptic Curve Diffie-Hellman is implemented. Instead of a function modulo p, the problem to resolve is an elliptic curve in the form of  that is more complex mathematically but needs less bits to perform the operation and hence is more and more privileged. The Diffie-Hellman protocol makes the version 4.2 of Bluetooth Low Energy robust against eavesdroppers.

Actualité

Sorry, your filter selection returned no results.

Nous avons mis à jour notre politique de confidentialité. Prenez un moment pour lire les changements. En cliquant sur "J'accepte", vous acceptez la clause de confidentialité d'Arrow Electronics ainsi que les conditions d'utilisation.

Notre site Internet place des cookies sur votre appareil pour améliorer votre expérience et pour améliorer notre site. Pour en savoir plus sur les cookies que nous utilisons et la façon de les désactiver, cliquez ici. Des cookies et des technologies de suivi peuvent être utilisés à des fins de marketing. En cliquant sur « Accepter », vous consentez au placement de cookies sur votre appareil et à notre utilisation de technologies de suivi. Cliquez sur « En savoir plus » pour de plus amples informations et instructions sur la façon de désactiver les cookies et les technologies de suivi. Même si l'acceptation des cookies et technologies de suivi est volontaire, leur désactivation peut entraîner un mauvais fonctionnement du site Internet et certaines publicités peuvent être moins pertinentes pour vous. Nous respectons votre confidentialité. Lisez notre politique de confidentialité ici.