Local bridge: socat 127.0.0.1:27015 to the desktop's usbmuxd, as a systemd user unit #8
Labels
No labels
bug
Claude
deferred
enhancement
epic
implementation
priority/high
priority/low
priority/med
research
verification
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Blocks
Depends on
#4 Build × Wine grid: which iTunes build installs, launches and renders
iTunes/iTunes.Wine
Reference
iTunes/iTunes.Wine#8
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The phone plugs into the same desktop that runs iTunes (operator, 2026-10-28; the native-install issue). #7 showed that iTunes in the prefix connects to TCP 127.0.0.1:27015 and speaks the usbmuxd protocol unchanged, and that Linux usbmuxd serves it behind a plain forward (KNOWLEDGE.md → Device service). Wine shares the host's loopback, so on the desktop the whole bridge is:
To build:
Check whether Fedora's usbmuxd runs only while a device is plugged in (udev-started) and what permissions
/var/run/usbmuxdhas, so the unit works as the user. Reconnecting per client (fork) should cover usbmuxd starting after iTunes.Done when, in the
fedora:44test container, the unit forwards iTunes to a usbmuxd stand-in on the Unix socket (wine/fakemux.py, given a Unix-socket mode), and iTunes lists the fake device. The real phone is the verification issue.What #7 settled for this bridge (KNOWLEDGE.md, Device service):
socat TCP-LISTEN:27015,bind=127.0.0.1,fork UNIX-CONNECT:/var/run/usbmuxdserved it as a listening client. So no translator is needed; the first attempt is plain forwarding.Start=4, as inresources/prefixes/mux), or it takes port 27015 itself. Its MobileDevice files are still needed. They install only from the patched MSI, because the service-permissions custom action fails under Wine.ssh -L(OpenSSH can forward to a Unix socket) → the desktop's/var/run/usbmuxd. Fedora starts usbmuxd only while an iPhone is plugged in. corellium's usbfluxd does the same TCP exposure, which is prior art for the network half.wine/fakemux.py, run on the far end of the forward, already getsListen,ListDevicesandConnectfrom iTunes.SystemConfiguration.plist,<UDID>.plist). Whether iTunes asks the mux (ReadPairRecord) or readsC:\ProgramData\Apple\Lockdowndirectly is still unknown. The first real lockdown session shows it in the usbmuxd log, which decides whether records need syncing.Bridge iTunes to the desktop's usbmuxd over the networkto Local bridge: socat 127.0.0.1:27015 to the desktop's usbmuxd, as a systemd user unitBuilt in
365f612.install.shwrites~/.config/systemd/user/itunes-wine-usbmuxd.service(socat TCP-LISTEN:27015,bind=127.0.0.1,reuseaddr,fork UNIX-CONNECT:/var/run/usbmuxd,Restart=on-failure,WantedBy=default.target) and runsenable --now. That call is guarded, so a session with no user manager (thefedora:44rig) gets a hint instead of an error.The done-when changed: the container/fakemux check was not run. This desktop has no Docker, and the real iPhone was here, which is the stronger control (#9, KNOWLEDGE.md → Desktop run). The bridge was first run by hand, with
-vcapturing every message. The phone appeared in iTunes:Listen→Attached→Connect 32498, and all 84 mux replies wereNumber 0. Then the operator raninstall.shand the unit took over:is-activeactive,is-enabledenabled, socat on 127.0.0.1:27015.Checked as asked: Fedora's usbmuxd is a static unit started by udev, and
/var/run/usbmuxdissrw-rw-rw-root, so a user unit can reach it.Found on the way: the AMDS MSI rolls back while the bridge holds 27015 (#11, fixed in the same commit).
Proposing the close: the decision is yours, because the done-when was swapped.
Closed by the operator (2026-10-28): the real-iPhone run replaces the container/fakemux done-when. Evidence is in the comment above and KNOWLEDGE.md → Desktop run (
365f612).