Description
Environment
iphone-control:v0.2.11(Linuxx86_64, native iOS 27 backend without WDA)- Device:
iPhone16,1(iPhone 15 Pro),iOS 27.0.1, English device language - Auto-unlock passcode configured (
6digits,UNLOCK-DISABLEDabsent)
Symptom
When the phone is locked (AFU) and an action triggers auto-unlock:
- The screen wakes and swipes up to the passcode keypad.
- Each of the 3 unlock rounds hides and re-opens the keypad without entering a single digit.
- The call fails with:
Couldn't bring up the passcode keypad (not a single digit was entered); unlock it by hand...
Debug log (ICTL_LOG=info,ictl_unlock=debug,ictl_daemon::tools::native=debug):
ictl_daemon::tools::native: native read: app pid 236 with 15 elements, 0 over it, app frame Some((0.0, 0.0, 393.0, 852.0)), screen 393x852
ictl_unlock: unlock round 2: locked, tree read with the check: true
ictl_unlock: unlock round 2: keypad found, passcode field None among 14 elements
Root cause (2 places)
-
crates/ictl-ax/src/xml.rs(kind/passcode_value, lines 110 & 143-147):On native iOS 27, the lock-screen passcode field arrives as
TextFieldand is only promoted toSecureTextFieldwhenpasscode_value(&e.value)returnstrue:fn passcode_value(v: &str) -> bool { let numbers = v.split(|c: char| !c.is_ascii_digit()).filter(|n| !n.is_empty()).count(); let lower = v.to_lowercase(); numbers == 2 && (v.contains("位") || lower.contains("passcode") || lower.contains("digit")) }
On real English iOS (
SBUIPasscodeEntryField), the accessibility label is"Passcode field"and the value is"0 of 6 values entered"(similarly French"0 valeur saisie sur 6", German"0 von 6 Werten eingegeben", Spanish"0 de 6 valores introducidos"). The value does not contain"位","passcode", or"digit", sopasscode_valuereturnsfalseandelements::passcode_fieldreturnsNone. -
crates/ictl-wda/src/elements.rs(parse_passcode_value, lines 793-800):match nums[..] { [total, entered] => Some((total, entered)), _ => None, }
Chinese puts total before entered (
"共6位数,已输入2位"->[6, 2]), while English/French/German/Spanish put entered before total ("0 of 6 values entered"->[0, 6]). Assigning[total, entered]positionally would parsetotal = 0and triggerLengthMismatch.
Suggested fix (verified locally on iPhone16,1, iOS 27.0.1)
- In
crates/ictl-ax/src/xml.rs, checke.label,e.identifier, ande.value(accepting localized labels like"Passcode field"/"Champ de code"and localized value phrases like"values entered"/"valeur saisie"alongside"位"/"passcode"/"digit"). - In
crates/ictl-wda/src/elements.rs, since0 <= entered <= totalholds in every locale (and order is irrelevant whenentered == total), returnSome((a.max(b), a.min(b)))whena.max(b) > 0.
After building v0.2.11 locally with those two changes and restarting the daemon, unattended auto-unlock succeeded on the first attempt (Unlocked automatically (8.3 s)).
Activity
Derrors commentedon Nov 24, 2026
Thanks for the detailed report and root-cause analysis. Both issues are confirmed, and the fix is in #176.
parse_passcode_value): returns(max, min)as you suggested, so the order no longer matters. This also fixes the WDA backend, which goes through the same function.ictl-axkind): the value must hold exactly two numbers with a non-zero larger one, plus any of:密码/passcode/champ de code),位/digit/entered/saisie/eingegeben/introducido…),Tests now include the English, French, German and Spanish values you gave. If you get a chance to try the PR branch on your iPhone 15 Pro, that would be a welcome extra check, since I haven't run it on an English-locale device myself.