Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't ask verification code and access forbiden and apple account block #21071

Closed
4 tasks done
ArkaitzSKR opened this issue Feb 23, 2023 · 202 comments · Fixed by #21072 or #21073
Closed
4 tasks done

Don't ask verification code and access forbiden and apple account block #21071

ArkaitzSKR opened this issue Feb 23, 2023 · 202 comments · Fixed by #21072 or #21073

Comments

@ArkaitzSKR
Copy link

ArkaitzSKR commented Feb 23, 2023

New Issue Checklist

Issue Description

When I try to log in to the apple account, it asks me for the username and password but not the verification code. The code arrives at the authorized apple devices but the fastlane application does not ask me for it and returns access forbiden.

Command executed
Complete output when running fastlane, including the stack trace and command used
 
   Please enter your Apple ID developer credentials
[11:54:57]: Apple ID Username:
apple@....
[11:56:15]: Logging in...
Password (for apple@...): **************
[11:56:45]: --------------------
[11:56:45]: fastlane init failed
[11:56:45]: --------------------
[11:56:45]: ["The request could not be completed because:", "Access forbidden"] 

Environment

 
✅ fastlane environment ✅

Stack

Key Value
OS 13.1
Ruby 3.1.3
Bundler? false
Git git version 2.34.1
Installation Source /opt/homebrew/Cellar/fastlane/2.212.0/libexec/bin/fastlane
Host macOS 13.1 (22C65)
Ruby Lib Dir /opt/homebrew/Cellar/ruby@3.1/3.1.3_1/lib
OpenSSL Version OpenSSL 3.0.7 1 Nov 2022
Is contained false
Is homebrew true
Is installed via Fabric.app false
Xcode Path /Applications/Xcode.app/Contents/Developer/
Xcode Version 14.2
Swift Version 5.7.2

System Locale

Variable Value
LANG en_US.UTF-8
LC_ALL
LANGUAGE

fastlane files:

No Fastfile found

No Appfile found

fastlane gems

Gem Version Update-Status
fastlane 2.212.0 ✅ Up-To-Date

Loaded fastlane plugins:

No plugins Loaded

Loaded gems
Gem Version
error_highlight 0.3.0
did_you_mean 1.6.1
atomos 0.1.3
rexml 3.2.5
CFPropertyList 3.0.6
claide 1.1.0
colored2 3.1.2
nanaimo 0.3.0
xcodeproj 1.22.0
rouge 2.0.7
xcpretty 0.3.0
terminal-notifier 2.0.0
unicode-display_width 1.8.0
terminal-table 1.8.0
plist 3.6.0
public_suffix 5.0.1
addressable 2.8.1
multipart-post 2.0.0
word_wrap 1.0.0
optparse 0.1.1
tty-screen 0.8.1
tty-cursor 0.7.1
tty-spinner 0.9.3
artifactory 3.0.15
babosa 1.0.4
colored 1.2
highline 2.0.3
commander 4.6.0
excon 0.99.0
faraday-em_http 1.0.0
faraday-em_synchrony 1.0.0
faraday-excon 1.1.0
faraday-httpclient 1.0.1
faraday-multipart 1.0.4
faraday-net_http 1.0.1
faraday-net_http_persistent 1.2.0
faraday-patron 1.0.0
faraday-rack 1.0.0
faraday-retry 1.0.3
ruby2_keywords 0.0.5
faraday 1.10.3
unf_ext 0.0.8.2
unf 0.1.4
domain_name 0.5.20190701
http-cookie 1.0.5
faraday-cookie_jar 0.0.7
faraday_middleware 1.2.0
fastimage 2.2.6
gh_inspector 1.1.3
json 2.6.1
mini_magick 4.12.0
naturally 2.2.1
rubyzip 2.3.2
security 0.1.3
xcpretty-travis-formatter 1.0.1
dotenv 2.8.1
bundler 2.3.26
simctl 1.6.10
jwt 2.7.0
uber 0.1.0
declarative 0.0.20
trailblazer-option 0.1.2
representable 3.2.0
retriable 3.1.2
mini_mime 1.1.2
memoist 0.16.2
multi_json 1.15.0
os 1.1.4
signet 0.17.0
googleauth 1.3.0
httpclient 2.8.3
webrick 1.8.1
google-apis-core 0.11.0
google-apis-playcustomapp_v1 0.12.0
google-apis-androidpublisher_v3 0.34.0
google-cloud-env 1.6.0
google-cloud-errors 1.3.0
google-cloud-core 1.6.0
google-apis-iamcredentials_v1 0.17.0
google-apis-storage_v1 0.19.0
rake 13.0.6
digest-crc 0.6.4
google-cloud-storage 1.44.0
emoji_regex 3.2.3
jmespath 1.6.2
aws-partitions 1.714.0
aws-eventstream 1.2.0
aws-sigv4 1.5.2
aws-sdk-core 3.170.0
aws-sdk-kms 1.62.0
aws-sdk-s3 1.119.1
set 1.0.2
forwardable 1.3.2
logger 1.5.0
pathname 0.2.0
shellwords 0.1.0
cgi 0.3.5
date 3.2.2
timeout 0.2.0
stringio 3.0.1
securerandom 0.2.0
uri 0.11.0
openssl 3.0.1
digest 3.1.0
io-nonblock 0.1.0
ipaddr 1.2.4
io-wait 0.2.1
zlib 2.1.1
resolv 0.2.1
time 0.2.0
open-uri 0.2.0
mutex_m 0.1.1
net-http 0.3.0
net-protocol 0.1.2
ostruct 0.5.2
english 0.7.1
erb 2.2.3
strscan 3.0.1
abbrev 0.1.0
io-console 0.5.11
tempfile 0.1.2
delegate 0.2.0
fileutils 1.6.0
tmpdir 0.1.2
base64 0.1.1
singleton 0.1.1
open3 0.1.1
nkf 0.1.1
prettyprint 0.1.1
pp 0.3.0
find 0.1.1
yaml 0.2.0
psych 4.0.4

generated on: 2023-02-23

@fastlane-bot
Copy link

It seems like you have not included the output of fastlane env
To make it easier for us help you resolve this issue, please update the issue to include the output of fastlane env 👍

@robertsammons
Copy link

Getting same issue, be careful as it completely locked my Apple account

@maitines
Copy link

Same here since this morning, including account blocking.

@MichaVanEijk
Copy link

Same here... Having it at both version 2.209.0 as the newest version 2.212.0..

@sahilit
Copy link

sahilit commented Feb 23, 2023

Facing same issue from morning.
Yesterday it was working fine

@motrieux-thomas
Copy link

Same here since this morning :/
It doesn't seem to be related to the fastlane version.
My account was also blocked.

@mcaylus
Copy link

mcaylus commented Feb 23, 2023

Same here - account blocked :-(

@vmontana
Copy link

vmontana commented Feb 23, 2023

Same symptoms here:

  • Access Forbidden error seen in match and spaceauth processes.
  • Happens in 2.209.1, 2.210.1 and 2.212.0 versions.
  • Yesterday it works fine.
  • The account was blocked by Apple. After I unlocked it on Apple portal, the issue persists.
  • I have been able to create a cookie session (spaceauth) in a machine on Dublin. The error persists in Spain (where I'm). Regional error? I don't think that it's a permanent solution since the cookie created in differents regions expires soon.

Anyone knows a possible fix?

Thanks!

@jacobsapps
Copy link

So has this just broken in the hour since my last deploy?

@WJacobsNL
Copy link

Still worked about 8 hours ago, but haven't worked for at least 4 hours since

@WesleyHilhorst
Copy link

This seems to be due to Apple being careless somehow. You can fix it by manually changing your password and unlock your account.

@GabrielMassana
Copy link

Same.
No time to enter the 6-digits code and Access forbidden

@WJacobsNL
Copy link

This seems to be due to Apple being careless somehow. You can fix it by manually changing your password and unlock your account.

I still have issues creating a new session using spaceauth then though, so my CI still can't run

@vmontana
Copy link

vmontana commented Feb 23, 2023

This seems to be due to Apple being careless somehow. You can fix it by manually changing your password and unlock your account.

It's not a fix in my case. After unlock it and change the password, the "Access forbidden" error persists.

@pablopag
Copy link

This seems to be due to Apple being careless somehow. You can fix it by manually changing your password and unlock your account.

We have unlocked the account and changed the account password but the issue persists. Every time we try we receive the 2FA code in the trusted device but fastlane is unable to present the form to type it, instead presents the error we are all seing. I am in Spain.

@ArkaitzSKR ArkaitzSKR changed the title Don't ask verification code and access forbiden Don't ask verification code and access forbiden and apple account block Feb 23, 2023
@theamiro
Copy link

theamiro commented Feb 23, 2023

I am in Kenya and my account was also locked. After changing the password the issue persists. It is not a geo-locked issue.

fastlane --version
fastlane 2.212.0

@PetterVangBraka
Copy link

I'm having the same issue with fastlane 2.212.0

@MichaVanEijk
Copy link

Okay, I got it working for me again now... I followed the following steps:

  1. Removing credentials from Fastlane via:
    fastlane fastlane-credentials remove --username APPLEUSERNAME

  2. Change password on Apple

  3. Adding credentials again
    fastlane fastlane-credentials add --username APPLEUSERNAME

In the last step, it asked me to authenticate again, filling in the new password and 2FA - after that, my normal flows started working again.

@Jarutais
Copy link

The last time I have used Fastlane was on Monday and one hour ago when I tried to log in to App Store Connect, my account was also blocked and required a password change. Maybe this isn't related to Fastlane at all but some problem on Apple's side.

@ArkaitzSKR
Copy link
Author

  1. fastlane fastlane-credentials remove --username APPLEUSERNAME

This has not worked for me. I keep getting the login to the authorized phone twice with its verification code but fastlane does not ask me for it.

@atacengiz
Copy link

Have the same exact issue, getting access forbidden in terminal but my account was not blocked when I try to login dev portal. (2 hours ago everything was working)

@Devorasolomon
Copy link

I have this two tried to remove credentials and didnt help

@borderleap-nate
Copy link

Same here... tried that and it didn't work.

@MichaVanEijk
Copy link

Maybe I just got lucky... 😞

@gonzalo-rivas
Copy link

Sending trough Xcode fails too. It is a collapse in appstore connect itself, no "breaking api changes" for apis like fastlane.

@igorgn
Copy link

igorgn commented Feb 23, 2023

Looks like it is not related to account settings, as all accounts has same Spaceship::AccessForbiddenError issue

@xalikoutis
Copy link

Same here i changed the password but the same happens
Could not login to App Store Connect Please check your credentials and try again. This could be an issue with App Store Connect, Please try unsetting the FASTLANE_SESSION environment variable by calling 'unset FASTLANE_SESSION' (if it is set) and re-run fastlane spaceauth`

Exception type: Spaceship::AccessForbiddenError`

@tugsadsen
Copy link

Same here...

@itaischuftan
Copy link

same here, all of our mobile CI is down due to this

@joshdholtz
Copy link
Member

@joshdholtz amazing work! When is version 2.212.1 going to be available via rubygems?

Once I figure out why my local release process is failing 🙈 But sooooooooooon

@joshdholtz
Copy link
Member

✨ Official Update 10

Okay! So 2.212.1 is out on RubyGems and is waiting for approval on Homebrew (probably out sometime today)

Release 👉 https://github.com/fastlane/fastlane/releases/tag/2.212.1

Hope this all works for everyone now! And... its been a pleasure talking to you all but let's not meet like this again 😉

@anilgr
Copy link

anilgr commented Feb 24, 2023

Thank you ! @joshdholtz

@StringKaori
Copy link

i can't update it, when i run fastlane update_fastlane it says Updating fastlane from 2.212.0 to 2.212.1... 🚀, but when i run fastlane --version it says i'm still on 2.212.0

@D3icidal
Copy link

i can't update it, when i run fastlane update_fastlane it says Updating fastlane from 2.212.0 to 2.212.1... 🚀, but when i run fastlane --version it says i'm still on 2.212.0

@StringKaori Is that a gem or homebrew installation? fastlane env can tell you.
Homebrew isn't ready yet but should be soon.

Okay! So 2.212.1 is out on RubyGems and is waiting for approval on Homebrew (probably out sometime today)

@justincbeck
Copy link

FWIW, fastlane update_fastlane worked for me.

@StringKaori
Copy link

i can't update it, when i run fastlane update_fastlane it says Updating fastlane from 2.212.0 to 2.212.1... 🚀, but when i run fastlane --version it says i'm still on 2.212.0

@StringKaori Is that a gem or homebrew installation? fastlane env can tell you. Homebrew isn't ready yet but should be soon.

Okay! So 2.212.1 is out on RubyGems and is waiting for approval on Homebrew (probably out sometime today)

@D3icidal homebrew

@D3icidal
Copy link

@StringKaori Actually can you try again? I just tried it again 10 minutes ago and brew was able to install it finally

@StringKaori
Copy link

it worked now, thanks

@deggertsen
Copy link

It's available on homebrew now. Thank you!

@courtsimas
Copy link

courtsimas commented Feb 24, 2023

For some reason fastlane 2.212.1 didn't fix it for me...

I even ran unset FASTLANE_SESSION and deleted the email from ~/.fastlane/spaceship/ , and then tried spaceauth.... still same issue.

UPDATE: Turns out my Apple ID was locked due to all the build attempts.

@carlosriveroib
Copy link

fastlane update_fastlane updated the version but still not working

Captura de pantalla 2023-02-24 a las 21 33 42

@justincbeck
Copy link

Confirmed. Thanks, so much!

@happycappie
Copy link

I also confirm that the PR worked for me (2FA with phone number code).

Thanks A LOT @joshdholtz ! 🚀

What's even better with this whole situation is that it was a great opportunity to move from 2FA / Session to AppStore Connect API Key. At the time we first implemented Fastlane -> AppStore Connect authentication, some key actions/tools we were using were not yet available using AppStore Connect API Key. Now it's all available.

The integration is very smooth compared to 2FA. I couldn't recommend more to anyone still having trouble here to use AppStore Connect API Key instead of 2FA.

Cheers 🍻

Do you know where we can see the scope of actions that are supported by the AppStore Connect API key? for example, can we use it create Apple Pass Type Identifiers and create NFC Certificates.

@mailyokesh
Copy link

changing to use api_key did the trick. Also api_key seems to be supporting most of the features now and we dont have to rotate the session every 30 days.

@mdgeist
Copy link

mdgeist commented Feb 25, 2023

changing to use api_key did the trick. Also api_key seems to be supporting most of the features now and we dont have to rotate the session every 30 days.

Just curious where did you use api_key?

@mdgeist
Copy link

mdgeist commented Feb 25, 2023

NFC Certificates

Check out Apple's API here:
https://developer.apple.com/documentation/appstoreconnectapi/certificatetype

These are the certificates you can generate with ASC API.

@superandrew213
Copy link

@courtsimas how did you unlock your Apple ID?

@courtsimas
Copy link

@superandrew213 I logged into appleid and it notified me there. Had to jump through a few screens to unlock it.

@ArkaitzSKR
Copy link
Author

✨ Official Update 10

Okay! So 2.212.1 is out on RubyGems and is waiting for approval on Homebrew (probably out sometime today)

Release 👉 https://github.com/fastlane/fastlane/releases/tag/2.212.1

Hope this all works for everyone now! And... its been a pleasure talking to you all but let's not meet like this again 😉

Thank you @joshdholtz !

@hervouinc
Copy link

hervouinc commented Feb 27, 2023

@conradpronto

Do you know where we can see the scope of actions that are supported by the AppStore Connect API key? for example, can we use it create Apple Pass Type Identifiers and create NFC Certificates.

Here is the scope of supported Fastlane actions/tools with API Key:
https://docs.fastlane.tools/app-store-connect-api/

@Lakston
Copy link

Lakston commented Feb 27, 2023

updating to 2.212.1 did not solve it for me

@carlosriveroib
Copy link

updating to 2.212.1 did not solve it for me

That happened to me. You have to go to appleId and create a new application password

@Lakston
Copy link

Lakston commented Feb 27, 2023

what do you mean by application password ?

@mlazari
Copy link

mlazari commented Feb 27, 2023

@Lakston I think he meant "application specific password" - https://support.apple.com/en-us/HT204397

@Lakston
Copy link

Lakston commented Feb 27, 2023

Ok our developpers account was blocked as mentionned by other people in this issue, I had to unblock it and change the password

@mailyokesh
Copy link

mailyokesh commented Feb 27, 2023

changing to use api_key did the trick. Also api_key seems to be supporting most of the features now and we dont have to rotate the session every 30 days.

Just curious where did you use api_key?

instruction on how to generate apikey https://docs.fastlane.tools/app-store-connect-api/
and then put it as a json file place it inside the fastlane folder

Here is my fastfile

default_platform(:ios)

platform :ios do
desc "Push a new beta build to TestFlight"
lane :beta do
upload_to_testflight(api_key_path: "fastlane/somefile.json",distribute_external: true, changelog:"02-27-2023 09:45:10")
end
end

contents of somefile.json placed inside fastlane folder
{
"key_id": "your key id",
"issuer_id": "your issuer id ",
"key": "-----BEGIN PRIVATE KEY-----\nMIGTAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBHknlhdlYdLu\n-----END PRIVATE KEY-----",
"duration": 1200,
"in_house": false
}

@joshdholtz joshdholtz unpinned this issue Sep 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet