Skip to content

Pin apple-private-apis: a wrong SMS code can be retyped - #15

Draft
gregakespret wants to merge 1 commit into
fix/mac-escrow-identityfrom
fix/retype-wrong-sms-code
Draft

gregakespret wants to merge 1 commit into
fix/mac-escrow-identityfrom
fix/retype-wrong-sms-code

Conversation

@gregakespret

@gregakespret gregakespret commented Oct 26, 2026 •

Copy link
Copy Markdown
Owner

Line 1's four PRs stay drafts because nothing yet shows Apple accepting a second code in the same sign-in.

Moves the apple-private-apis submodule to 56f0dea, the head of gregakespret/apple-private-apis#8. With it, a wrong SMS code that Apple will take another try for (-21669) no longer fails AppleAccount::login. The login asks the 2FA prompt again for the same text, and no new text is sent.

The 2FA closure becomes Fn(TfaPrompt) -> Option<String>. TfaPrompt carries the texted phone, as before, and refused, how many codes Apple has refused for this text. The two console closures in src/test.rs ignore the prompt and wrap their input in Some. cargo check --bin rustpush-test --features macos-validation-data passes. The library itself has no other callers of the closure.

Draft until #8 merges and is verified against Apple. The same sign-in accepting a second code is Apple's invitation ("Try entering your verification code again."), not something a log has shown. Merge order: apple-private-apis#8, then this, then re-pin gregakespret/export-findmy's Cargo.lock to this branch's merge commit.

This conflicts with #9, which changes the same closure argument to CodeSentTo.

🤖 Generated with Claude Code

https://claude.ai/code/session_01JvDrSTtCSuxsh3iMaZ8sPX

On Apple's -21669 ("Try entering your verification code again.") the
login now asks for the code again for the same text instead of failing
with Bad2faCode. The 2FA closure takes a TfaPrompt (the texted phone,
plus how many codes Apple has refused for this text) and returns
Option<String>; the console callers in src/test.rs ignore the prompt.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JvDrSTtCSuxsh3iMaZ8sPX
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