Sign in with the app-specific password you generated. If you forgot the app-specific password or need to create a new one -22938 Sign in with the app-specific password you generated. If you forgot the app-specific password or need to create a new one -22938 ios ios

Sign in with the app-specific password you generated. If you forgot the app-specific password or need to create a new one -22938


Solution

As the error message says, we need to create an app-specific password at the:

http://appleid.apple.com

address. Go to the security section and use the Generate Password.

Generate Password

Use the Generate Password link to create a new password. Copy and paste the password and don't forget you won't be able to find the password again after you click on the Done button.

FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD

Then, set the FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD environment variables at your bash or your .bash_profile file. This file could be different depending on your choice for the bash on your terminal. For example, if your bash of choice is ZSH like mine, you need to edit the .zshrc file.

Then re-run your Fastlane with:

bundle exec fastlane beta --verbose

Note: When you can not enter the security code manually, as on a Continuous Integration system, you have to use other ways to log in. The application-specific password will not work if your action usage does anything else than uploading the binary, e.g. updating any metadata like setting release notes or distributing to testers, etc.

Generating a login session for Apple ID

As your CI machine will not be able to prompt you for your two-factor authentication or two-step verification information, you need to generate a login session for Apple ID in advance. You can get on your local machine this by running:

fastlane spaceauth -u user@email.com

for more, please check the fastlane documentation .

Hope this helps!


Here is a screnshot of the errorenter image description here

and here is where to create the app-specific passwordenter image description here


I met the issue, but set the FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD environment variables at .zshrc (I'm using ZSH) didn't work.

Instead, I set that var in Fastfile:

before_all do  ...  ENV['FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD']= 'xxxx-xxxx-xxxx-xxxx'  ...end