Bluetooth & BLE · Study deck

BLE Encryption: Secure Pairing

A sensor with no screen still needs safe pairing.

Radio Remi is your guide for this deck.

securityencryptionkeys
Radio Remi, the module guide, in a scene from this chapter.
iotclass.org

After studying this chapter

Learning objectives

You will be able to:

  • Test pitfall: using "just works" pairing because the device has no display with a concrete scenario and pass criteria.
  • Validate deep dive: key lifecycle, privacy addresses, and signed data evidence with a concrete scenario and pass criteria.
  • 'test pitfall: using "just works" pairing because the device has no display with a concrete scenario and pass criteria'
  • 'validate deep dive: key lifecycle, privacy addresses, and signed data evidence with a concrete scenario and pass criteria'
iotclass.org

Major section

Worked Example: Quantifying BLE Pairing Attack Surfaces

A medical device manufacturer is designing a BLE-connected insulin pump.

  • The pump communicates with a companion smartphone app to receive bolus dose commands.
  • The design team must choose the appropriate BLE security level.
  • Threat Analysis -- What Happens If Pairing is Compromised?: An attacker who performs a MITM during pairing becomes the bonded device.

Why it matters

Just Works: The risk is active MITM or pairing hijack during the setup window because there is no user-authenticated check.

iotclass.org

Major section

Worked Example: Quantifying BLE Pairing Attack Surfaces (continued)

Passkey with Legacy pairing: The risk is a captured pairing exchange combined with low-entropy passkey material.

  • OOB using NFC or QR: The attacker must compromise the out-of-band channel as well as the BLE exchange, which materially raises the bar.
  • Key rotation: The pump re-pairs weekly.
  • Compromised keys expire automatically.
iotclass.org

Major section

Worked Example: Quantifying BLE Pairing Attack Surfaces (continued)

An attacker must be physically within 4 cm -- essentially impossible without being noticed in a clinical setting.

  • An attacker who somehow bonds still cannot issue a valid dose command without the clinician's PIN.
  • OOB pairing: Adds hardware or provisioning-flow complexity, but removes the remote pairing MITM path.
  • Application-layer PIN or role check: Adds a small user step for high-risk commands, but blocks unauthorized commands even if a bond is misused.
iotclass.org

Major section

Worked Example: Quantifying BLE Pairing Attack Surfaces (continued)

Periodic re-authentication: Adds occasional friction, but limits how long a compromised bond remains useful.

  • Combined result: Pairing protects the link, authorization protects the action, and revocation limits persistence.
  • Key Insight: OOB pairing removes the primary remote MITM path, while application-layer authorization adds an independent barrier for dose commands.
  • Neither layer alone is sufficient for a life-safety device, but together they provide defense-in-depth with manageable user friction.
iotclass.org

Major section

Concept Relationships:

Key hierarchy and bonding: Session keys and stored keys determine whether reconnection can happen securely without re-pairing.

  • Pairing methods and key generation: Authentication strength during pairing determines whether encryption protects the right peer.
  • CSRK and data integrity: Signature keys verify authenticity on unencrypted LE links, but they are not a substitute for encryption where confidentiality matters.
  • AES-CCM-128 and link encryption: Link encryption protects post-pairing traffic once trusted keys are available.

Why it matters

IRK and privacy: Identity resolving keys allow bonded devices to recognize private rotating addresses without exposing a stable public address.

iotclass.org

Major section

Deep Dive: Key Lifecycle, Privacy Addresses, and Signed Data Evidence

Encryption is only part of the BLE security record.

  • Purpose-specific derivation limits what one key can authorize; rotation or revocation then leads to verified destruction and audit evidence, with the loop reopening when ownership or risk changes.
  • Resolvable Private Addresses make the IRK role concrete.

Key terms

CSRK signed data
CSRK signed data is a different tradeoff.
Key-management lifecycle evidence loop with generation, provisioning, protected storage, purpose-key derivation, rotation, revocation, destruction, and audit evidence
Key-management lifecycle evidence loop with generation, provisioning, protected storage, purpose-key derivation, rotation, revocation, destruction, and audit evidence
iotclass.org

Major section

Deep Dive: Key Lifecycle, Privacy Addresses, and Signed Data Evidence (continued)

For BLE bonds, the inventory should therefore name each LTK, IRK, and CSRK owner, purpose, state, storage boundary, and revocation path.

  • A sensor can rotate its over-the-air address periodically so a passive scanner sees unrelated-looking identifiers, while a bonded gateway uses the stored IRK to resolve those addresses as the same trusted device.
  • CSRK signed data is a different tradeoff.
  • Bond deletion must remove all relevant keys.
iotclass.org

Deck summary

Key takeaways

A medical device manufacturer is designing a BLE-connected insulin pump.

  • Passkey with Legacy pairing: The risk is a captured pairing exchange combined with low-entropy passkey material.
  • An attacker must be physically within 4 cm -- essentially impossible without being noticed in a clinical setting.
  • Periodic re-authentication: Adds occasional friction, but limits how long a compromised bond remains useful.
  • Key hierarchy and bonding: Session keys and stored keys determine whether reconnection can happen securely without re-pairing.
iotclass.org

Retrieval practice

Recall check 1 of 4

Radio Remi says: answer from memory, then check your reasoning.

Q1What is the role of the Long Term Key (LTK) in BLE security?

AIt encrypts data only during the initial pairing session and is then discarded
BIt is stored after bonding to enable secure reconnection without re-pairing
CIt resolves private MAC addresses to prevent device tracking
DIt signs unencrypted data packets to verify integrity
Show answer

Answer: B The LTK is a 128-bit key saved during bonding so that two devices can re-establish an encrypted link in future sessions without repeating the full pairing ceremony.

iotclass.org

Retrieval practice

Recall check 2 of 4

Radio Remi says: answer from memory, then check your reasoning.

Q2Which pairing method should be used for a BLE-connected medical glucose monitor?

AJust Works, because medical devices need fast connection without user interaction
BPasskey Entry with a static PIN printed on the device label
COut-of-Band (OOB) pairing using NFC or QR code, combined with application-layer authorization
DNo pairing needed if the application layer uses its own encryption
Show answer

Answer: C OOB pairing requires physical access to pair (NFC tap or QR scan), providing strong MITM protection.

iotclass.org

Retrieval practice

Recall check 3 of 4

Radio Remi says: answer from memory, then check your reasoning.

Q3What key improvement does LE Secure Connections (BLE 4.2+) provide over Legacy Pairing?

AIt uses AES-256 instead of AES-128 for stronger encryption
BIt uses Elliptic Curve Diffie-Hellman
CIt eliminates the need for any pairing method, making connections automatic
DIt extends BLE range from 10 meters to 100 meters
Show answer

Answer: B LE Secure Connections uses ECDH on the P-256 curve for key agreement, so a passive attacker who records the pairing exchange cannot derive the shared keys.

iotclass.org

Retrieval practice

Recall check 4 of 4

Radio Remi says: answer from memory, then check your reasoning.

Q4Place each BLE security item where it lives so you can choose the right key job and avoid treating every security control as link encryption.

ALong Term Key (LTK)
BIdentity Resolving Key (IRK)
CConnection Signature Key (CSRK)
DAES-CCM Encryption
Show answer

Answer: A Separate relationship keys, signed-data authentication, and packet protection so you can explain which BLE property each item supplies and which property it does not.

Q5Complete the authorization logic for a high-risk BLE command after bonding:

Aif not ctx.ble_encrypted:
Bif ctx.rssi < -70:
Cif command not in HIGH_RISK:
Dif ctx.device_name is None:
Show answer

Answer: A Bonding and link encryption are necessary but not sufficient for high-risk commands.

iotclass.org

Print reference

Answers 1 of 2

Answer key.

  1. B · The LTK is a 128-bit key saved during bonding so that two devices can re-establish an encrypted link in future sessions without repeating the full pairing ceremony.
  2. C · OOB pairing requires physical access to pair (NFC tap or QR scan), providing strong MITM protection.
  3. B · LE Secure Connections uses ECDH on the P-256 curve for key agreement, so a passive attacker who records the pairing exchange cannot derive the shared keys.
iotclass.org

Print reference

Answers 2 of 2

Answer key.

  1. A · Separate relationship keys, signed-data authentication, and packet protection so you can explain which BLE property each item supplies and which property it does not.
  2. A · Bonding and link encryption are necessary but not sufficient for high-risk commands.
iotclass.org