Repository navigation
Conversation
|
Thanks for working on this! Quick question about the macOS ADI backend: macos.py pins adid to SHA-256 4b6b320f08edcf5d65ed1141399b76a8d9323fee2045c577c5d2f30f35a5dae1, but I can't find which macOS version that /usr/libexec/adid comes from. Which exact macOS 26 build produced it (e.g. 26.6.2 / 25G83)? I'm on Windows with no Mac, so I'd need to pull the file from a matching build. Thanks! |
|
@rabea98 it should be the latest available 26.X image, and then once you get the adi you have to take out the x86 part because is a fat one. I can check later tonight or tomorrow morning before making you download the wrong one. ideally anything should work tho. I also tried another earlier MacOS i can't remember. I guess from 26.X you can pick any random one |
|
@rabea98 macOS 26.7.1 (25G241) x86_64 adid |
|
Tested the proposed local macOS ADI backend with Home Assistant running in a Linux Mint x86_64 container (Python 3.14). Build and setup Built the Python wheels in the HA environment from these commits: The emulator booted and the local Anisette provider initialized. |
Since 2026-10-12 a password Apple accepts but wants a code for is answered at the SRP complete step with hsc 409 and no au. au is what _gsa_authenticate reads to decide that a code is needed, so the sign-in was taken as finished, the code was never asked for, and the mobileme delegate login after it failed with status=1 (malmeloo#278, OpenTagViewer#248). _normalize_2fa_status fills au in as trustedDeviceSecondaryAuth, which is how sacca97/os-findmy-e signs in. Same name and placement as malmeloo#279, so a later sync with upstream is a no-op here. A 409 that does name au is left as Apple sent it. OpenTagViewer did this by wrapping _gsa_request on each account at runtime; with this it can drop that. The tests run the whole SRP exchange offline against a verifier built from the same password, so they exercise _gsa_authenticate's own decision. Without the call, the 409 test fails with AUTHENTICATED. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015MJtmGkNZpfzFGSN1BZ82a
The fix belongs in FindMy.py's _gsa_authenticate, where malmeloo/FindMy.py#279 adds _normalize_2fa_status; the same change is prepared for parawanderer/FindMy.py. Until the pin moves, _treatHsc409AsSecondFactor keeps wrapping _gsa_request, but returns without touching the account when the pinned FindMy.py has the function. test_the_pinned_findmy_does_not_yet fails on the pin move, which is the cue to delete the wrapper. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_015MJtmGkNZpfzFGSN1BZ82a
|
Very nice work. This combined with malmeloo/Anisette.py#6 works for me on Linux. The old Android-based backend seems to have stopped authenticating recently. |
|
👋 Another working setup: (x86_64, HA 2026.11.3) with this PR ( FYI, The |
|
Another data point, with one extra fix that was needed here. Setup: Home Assistant OS with this PR ( GSA 503 without For me every A request shaped like headers = {
"Content-Type": "text/x-xml-plist",
"Accept": "*/*",
"User-Agent": "akd/1.0 CFNetwork/978.0.7 Darwin/18.7.0",
"X-MMe-Client-Info": self._anisette.client,
+ # Apple's edge answers 503 to Grand Slam requests without the machine ID header.
+ "X-Apple-I-MD-M": cpd["X-Apple-I-MD-M"],
}Others here don't hit it, so it may be a staged rollout on Apple's side, but the header is harmless when it isn't required. Could it go into this PR? Installing in Home Assistant HA installs integration requirements with |
and [Anisette.py PR malmeloo#6](malmeloo/Anisette.py#6). It emulates Apple's macOS ADI daemon instead of the Android libraries used by the default integrated provider. An example CoreADI.x86_64 can be downloaded from https://sharebin.eu/files/CoreADI.x86_64, as shared in malmeloo/Anisette.py#6 To be stored in /config/.storage/findmy/CoreADI.x86_64 Under **Advanced options**, enable **Use experimental macOS Anisette backend** and leave **Remote Anisette URL** empty.
Some changes required by the new anisette backend system to be coherent when sending requests to apple servers + fixes of issues encountered along the way.
Some tests might be removed eventually.
Fixes #278