Skip to content

Commit cbf359f

Browse files
DerekSeamanclaude
andcommitted
Add GrapheneOS troubleshooting section to README
GrapheneOS enforces mandatory MITM-authenticated pairing for HID Keyboard devices, causing Just Works pairing to fail with "Incorrect PIN or passkey". The captured IRK is unusable because the bond is never cleanly completed. Solution is to switch to Heart Sensor profile. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent d0a6a94 commit cbf359f

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -383,6 +383,26 @@ If the Developer Options fix doesn't work, or you're on a non-Samsung Android de
383383
5. The pairing dialog should appear, allowing the bonding process to complete
384384
6. Look for the captured IRK in the ESP32 logs or the ESPHome device page
385385

386+
### GrapheneOS / Hardened Android — "Incorrect PIN or passkey" Error
387+
388+
GrapheneOS (and some other hardened Android builds) enforces **mandatory authenticated pairing** for HID Keyboard devices. Because a Bluetooth keyboard could theoretically inject keystrokes, GrapheneOS requires a PIN or passkey confirmation before completing the bond. IRK Capture uses "Just Works" pairing (no PIN), so GrapheneOS rejects the Keyboard profile pairing and shows "Incorrect PIN or passkey" on the phone.
389+
390+
**Symptoms:**
391+
- Phone shows "Incorrect PIN or passkey" during pairing
392+
- An IRK may appear in the logs and ESPHome device page, but pasting it into the Private BLE Device integration reports "The provided IRK does not match any BLE devices that Home Assistant can see"
393+
- After rotating the ESP32 MAC address and retrying, the connection fails with `ENC_CHANGE status=1035`
394+
395+
The captured IRK is invalid for use in Home Assistant because GrapheneOS considers the bond incomplete and may immediately rotate to a new RPA key state, or the IRK is from a pairing that was aborted before HA's passive scanner could see the device advertising with it.
396+
397+
**Solution: Switch to the Heart Sensor profile.**
398+
399+
GrapheneOS does not enforce MITM-authenticated pairing for heart rate sensors, so Just Works pairing succeeds cleanly and the captured IRK will work correctly.
400+
401+
1. On the ESPHome device page in Home Assistant, change **BLE Profile** to **"Heart Sensor"**
402+
2. Wait ~30 seconds for the ESP32 to reboot and begin advertising
403+
3. On your GrapheneOS phone, open Bluetooth settings and pair to the heart rate sensor device
404+
4. The IRK will be captured and published — use it in the Private BLE Device integration as normal
405+
386406
### Android Watches
387407

388408
Many Android watches aggressively filter BLE devices, and by default neither the keyboard or heart sensor will be shown as a pairable device. However, the app "Gear Tracker II" (no affiliation) overcomes this aggressive BLE filtering and should allow you pair your watch to the ESP32 and extract the IRK.

0 commit comments

Comments
 (0)