I see that the code is expecting a hash with a key of trustedDevices but the response Apple is sending me doesn't contain that key. Has that changed to trustedPhoneNumbers? I tried modifying the gem's code to look for that instead and it got a little further. The code got to the point of trying to list devices for me to choose but then it failed with: NoMethodError: undefined method 'choose' for #<Spaceship::PortalClient:0x007f8c9b38c398>. So I'm guessing that a lot has changed in that response from Apple.
Has Apple changed the format of the 2 Step response? I'm getting this from
two_step_client.rb:43:in 'handle_two_step'
:Invalid 2 step response {"trustedPhoneNumbers"=>[{"id"=>1, "pushMode"=>"sms", "obfuscatedNumber"=>"(•••) •••-••53"}], "securityCode"=>{"length"=>6, "tooManyCodesSent"=>false, "tooManyCodesValidated"=>false, "securityCodeLocked"=>false}, "authenticationType"=>"hsa2", "recoveryUrl"=>"https://iforgot.apple.com/phone/add?prs_account_nm=abcxyz@gmail.com&autoSubmitAccount=true&appId=142", "cantUsePhoneNumberUrl"=>"https://iforgot.apple.com/iforgot/phone/add?context=cantuse&prs_account_nm=abcxyz@gmail.com&autoSubmitAccount=true&appId=142", "recoveryWebUrl"=>"https://iforgot.apple.com/password/verify/appleid?prs_account_nm=abcxyz@gmail.com&autoSubmitAccount=true&appId=142", "repairPhoneNumberUrl"=>"https://gsa.apple.com/appleid/account/manage/repair/verify/phone", "repairPhoneNumberWebUrl"=>"https://appleid.apple.com/widget/account/repair?#!repair", "aboutTwoFactorAuthenticationUrl"=>"https://support.apple.com/kb/HT204921", "trustedPhoneNumber"=>{"id"=>1, "pushMode"=>"sms", "obfuscatedNumber"=>"(•••) •••-••53"}, "hsa2Account"=>true, "supportsRecovery"=>true, "managedAccount"=>false}
I see that the code is expecting a hash with a key of
trustedDevices
but the response Apple is sending me doesn't contain that key. Has that changed totrustedPhoneNumbers
? I tried modifying the gem's code to look for that instead and it got a little further. The code got to the point of trying to list devices for me to choose but then it failed with:NoMethodError: undefined method 'choose' for #<Spaceship::PortalClient:0x007f8c9b38c398>
. So I'm guessing that a lot has changed in that response from Apple.