Skip to content

11.2a: Wi-Fi without usbmuxd - #97

Merged
SirReaDy merged 2 commits into
mainfrom
feat/wifi-direct
Oct 22, 2026
Merged

SirReaDy merged 2 commits into
mainfrom
feat/wifi-direct

Conversation

@SirReaDy

Copy link
Copy Markdown
Collaborator

First part of 11.2. A device this computer has opened before is found on the local network and reached straight at its address, without the system's usbmuxd. That gives Wi-Fi installs on Linux without usbmuxd, and on systems where Apple's own Wi-Fi discovery doesn't list the device.

How it works

  • Discovery: mDNS for _apple-mobdev2._tcp, sent from a UDP port of IPAForge's own so devices answer straight back to it (RFC 6762 §6.7). It never binds 5353, so it doesn't compete with Bonjour or avahi. Queries go every 10 s, out of every IPv4 interface. A device is gone after its goodbye, or three silent rounds.
  • Matching: on iOS 26.4 and later, by the advert's authTag: exactly 8 bytes of HMAC-SHA256 over its identifier, keyed with HKDF-SHA512 of the pair record's HostID, compared in constant time. This survives Private Wi-Fi Address, which changes the MAC on every network. Otherwise by the MAC address in the advert's name. Adverts from devices this computer isn't paired with are ignored. Matching only decides where to connect: every session is still authenticated by the TLS pin to the pair record's device certificate.
  • Connecting: one routing point for every connection: usbmuxd, or TCP to the device's address (lockdown on 62078, then each service's port), with the same pairing and TLS. Without usbmuxd, IPAForge's own pair record is used.
  • Link order: USB, then straight over Wi-Fi (16–18 MiB/s measured), then usbmuxd's own Wi-Fi link (6.4 MiB/s).
  • Wi-Fi on by default: whenever a session opens, EnableWifiConnections is turned on if it's off (the same setting as Finder's "Show this iPhone when on Wi-Fi"), and the device is remembered with its UDID and real Wi-Fi MAC. Best-effort: it never fails a session.

macOS

  • The Local Network usage reason in Info.plist, translated into all six languages (build/mac-locales), plus the Bonjour types.
  • When access is refused: device.local_network_denied with a recovery action, and a notice on the Devices page with Open Local Network settings (that one settings URL is allowlisted).

Also

  • The device feed merges Wi-Fi devices by UDID and keeps searching when usbmuxd is missing. A new network event says when local network access is refused.
  • device-probe wifi-list, plus --direct on any command to go straight over Wi-Fi only.
  • Docs: device.md, installing.md, rpc.md, ui.md, architecture, failure catalogue, both roadmaps.

Checks

  • On an iPhone on iOS 26.6.1 over Wi-Fi: wifi-list found it (matched by authTag, since its MAC was private), info --direct opened a session, and a full SideStore install straight over Wi-Fi completed.
  • pnpm verify, and the tests run twice under full CPU load.
  • The full browser suite, including the new Devices screen in every language, light and dark.
  • Windows and Linux runs with a real iPhone are still to do before release.

A device this computer has opened before is found on the local network and
reached straight at its address, without the system's usbmuxd: Wi-Fi
installs on Linux without usbmuxd, and where Apple's own Wi-Fi discovery
doesn't list the device.

- Discovery: mDNS for _apple-mobdev2._tcp from a UDP port of IPAForge's
  own (answers come straight back, never competing with Bonjour or avahi
  on 5353), every 10 s, out of every IPv4 interface. A device is gone
  after its goodbye or three silent rounds.
- Matching: the iOS 26.4+ authTag (exactly 8 bytes of HMAC-SHA256 over the
  advert's identifier, keyed with HKDF-SHA512 of the pair record's HostID,
  compared in constant time), which survives Private Wi-Fi Address; else
  the MAC address in the advert's name. Unknown devices are ignored, and
  the TLS pin to the pair record's device certificate still authenticates
  every session.
- Connecting: one routing point for every connection: usbmuxd, or TCP to
  the device's address (lockdown on 62078, then each service's port), same
  pairing and TLS. Without usbmuxd, IPAForge's own pair record is used.
- Link order: USB, then straight over Wi-Fi (16-18 MiB/s measured), then
  usbmuxd's own Wi-Fi link (6.4 MiB/s).
- Wi-Fi on by default: whenever a session opens, EnableWifiConnections is
  turned on if it is off, and the device is remembered (UDID, real Wi-Fi
  MAC). Best-effort; never fails a session.
- macOS: the Local Network usage reason in Info.plist (translated in six
  languages) and the Bonjour types; device.local_network_denied with a
  recovery action, and a Devices page notice with Open Local Network
  settings (that one settings URL allowlisted).
- The device feed merges Wi-Fi devices by UDID and keeps searching when
  usbmuxd is missing; a network event says when local network access is
  refused.
- device-probe: wifi-list and --direct (any command, straight over Wi-Fi).
- Tests: DNS codec, an independent authTag vector, the search, a fake
  Wi-Fi in the fake usbmuxd (direct TCP and mDNS answers), the device
  feed, the Node adapters, the notice; browser checks for the new screen.
An advert with authTags (iOS 26.4+) and no tag of this computer's is never matched by the MAC address in its name; the MAC is only for adverts without tags. Every session is still authenticated by the TLS pin to the pair record's device certificate.
@SirReaDy
SirReaDy merged commit 606379e into main Oct 22, 2026
12 checks passed
@SirReaDy
SirReaDy deleted the feat/wifi-direct branch October 22, 2026 12:15
@SirReaDy SirReaDy mentioned this pull request Nov 17, 2026
SirReaDy added a commit that referenced this pull request Nov 17, 2026
Version **0.1.0-alpha.8**: `apps/desktop/package.json`, the release
notes (`docs/releases/0.1.0-alpha.8.md`, used for the GitHub release and
the website), What's new and the changelog in the app, the README's
alpha line, and the roadmap.

**What's in it**
- The setup guide and the tour of the pages, with SideStore installed
  from the guide (#95, #96)
- Settings in tabs (#95)
- Wi-Fi without usbmuxd (#97)
- The iOS 17.4+ device tunnel over USB and Wi-Fi, and device sessions
  inside it (#98, #99, #100)
- Apple TV and Vision Pro paired by the code they show (#104)
- Expired apps whose profile iOS removed are listed and refreshed (#103)
- Paid teams are no longer stopped by the App ID limit (#107)


**Not tested on real hardware:** Apple TV and Vision Pro pairing (fakes
only), and the Wi-Fi tunnel beyond the iPhones it was tried on. The
release notes say so under "Known limits".
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant