Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion findmy/reports/account.py
Original file line number Diff line number Diff line change
Expand Up @@ -979,7 +979,7 @@ async def _gsa_request(self, parameters: dict[str, Any]) -> dict[str, Any]:
"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,
"X-MMe-Client-Info": self._anisette.client_akd,
}

resp = await self._http.post(
Expand Down
11 changes: 11 additions & 0 deletions findmy/reports/anisette.py
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,17 @@ def client(self) -> str:
"<com.apple.AOSKit/282 (com.apple.dt.Xcode/3594.4.19)>"
)

@property
def client_akd(self) -> str:
"""
Client string identifying as ``akd``, the daemon that performs Grand Slam requests.

Same format and platform as :attr:`client`, differing only in the app bundle.
Apple's GSA endpoint refuses requests that identify as Xcode with an HTTP 503,
so this is the string to send alongside an ``akd`` user agent.
"""
return "<MacBookPro18,3> <Mac OS X;13.4.1;22F8> <com.apple.AOSKit/282 (com.apple.akd/1.0)>"

async def get_headers(
self,
user_id: str,
Expand Down
Loading