Invalid Apple credentials for build:ios

Hello Expo team,

I am having an issue when I try to run “exp build:ios”.

This is the error message I receive:
Error while gathering & validating credentials
[exp] Reason:Invalid credentials, raw:“Invalid username and password combination. Used ‘XXXXX’ as the username.”
[exp] Set EXPO_DEBUG=true in your env to view the stack trace.

I have an apple developer membership account and I am able to log onto the apple developer website. What could be causing this issue? Let me know if you need any more information. Some more verbose error messaging would be helpful here because my credentials are clearly not the problem. Thanks.

Hi @firefox456 - I know it sounds silly but is there any chance you made a typo in your password? Have you tried entering it in again? I’m not sure why this would be happening otherwise. Another option is always to generate your own certificate/p12 file - you can follow the guide linked on this page . Sorry for the trouble!

Thanks for the quick reply. I have tried resubmitting my credentials more times then I can count. I am able to login to my apple developers account with the same credentials. I am enrolled in the Apple developer enterprise program. I set my EXPO_DEBUG environment variable to true. Is there any way to see more verbose errors for this issue? I have tried to clear my current credentials with -c many times as well. Thanks.

Thanks for the info @firefox456. Pinging @edgar - can you help out here?

@firefox456 Hi, just published a release of exp that will print out what apple credentials you’re using when EXPO_DEBUG=true as env variable. Whatever that is is what is used as your input by exp to apple servers.

1 Like

I have the same issue, it has to be due to recent updates. I used to build and submit few months back and it used to work flawlessly now "Invalid username and password combination. "

Despite how many times I enter correctly my username and password

@xbsdeset Your username & password are passed exactly as you put them in.

I tried both

I will provide all the credentials and files needed, Expo does limited validation
Expo handles all credentials, you can still provide overrides

I even disabled the 2 factor authentication, earlier this used to work. Is expo using some website /app of iosconnect where my account is disabled and I can figure out what’s wrong.

Btw I am using windows.

I would enable 2FA back on. And show your error message if you have one.

Do try to be on latest version of exp, also can you do in powershell.

bash.exe -c 'uname -a'

(Also please make your own forum thread when you have an issue)

@edgar Sorry about using the same thread.

bash.exe -c ‘uname -a’

Below is output
MINGW64_NT-10.0 XBSDZ 2.5.0(0.295/5/3) 2016-03-31 18:47 x86_64 Msys

It used to work in the earlier versions

This is the wrong bash.exe.

You need to be using the one provided by WSL, that is officially provided by Windows.

When I use powershell, the command says.

Linux XBSDZ 4.4.0-43-Microsoft #1-Microsoft Wed Dec 31 14:42:53 PST 2014 x86_64 x86_64 x86_64 GNU/Linux

When I use wsl it says

Operation not supported .

Do you have a bash at: C:\\Windows\\system32\\bash.exe ?
some instructions:

Download from the Windows app
store a distribution of Linux, then in an admin powershell, please run:

Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux

and run the new Linux installation at least once

I do have bash, does this mean. I have to install exp for the linux subsystem

No, it means that you need to have a working bash at: C:\\Windows\\system32\\bash.exe.

so when you do:

 C:\\Windows\\system32\\bash.exe -c 'uname -a`

everything should work.

I installed exp on linux subsystem and tried to build it worked.
I ran below command

C:\Windows\system32\bash.exe -c 'uname -a`
and got
Linux XBSDZ 4.4.0-43-Microsoft #1-Microsoft Wed Dec 31 14:42:53 PST 2014 x86_64 x86_64 x86_64 GNU/Linux

But it doesn’t work via gitbash like it used to, but it worked like a charm on sys bash.
So sorry, I am asking too many questions :frowning:

Also why when I build even when I had that issues, my production release would be replaced with this one.

Okay so to be clear, exp build:ios works for you now?

(Ask as many questions as you want :slight_smile: )

Yes but after I installed exp on my substem linux. Not via windows.

What version of exp are you on and what is the error when you do it on windows?

Exp version 49.2.2
And now on windows it says

Using existing credentials for this build
Well the build is working on windows too
Not sure what happened but you are my hero @edgar