You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Firebase CLI Version: 13.33.0
Node.js Version: v20.10.0
Linux 6.12.13-amd64
[REQUIRED] Test case
Download firebase-tools or firebase-cli and authenticate from the terminal
[REQUIRED] Steps to reproduce
Execute firebase login, firebase login --reauth, firebase login --no-localhost and basically all versions of authentication available. Including ones with login:ci
[REQUIRED] Expected behavior
The authentication should complete successfully within the terminal
[REQUIRED] Actual behavior
The CLI opens a browser window for authentication.
The browser displays the following error message:
Oops!
Firebase CLI Login Failed
The Firebase CLI login request was rejected or an error occurred. Please run firebase login again or contact support if you continue to have difficulty logging in.
Meanwhile, the terminal outputs the following logs:
Firebase optionally collects CLI and Emulator Suite usage and error reporting information to help improve our products. Data is collected in accordance with Google's privacy policy (https://policies.google.com/privacy) and is not used to identify you.
? Allow Firebase to collect CLI and Emulator Suite usage and error reporting
information? Yes
i To change your data collection preference at any time, run `firebase logout` and log in again.
Visit this URL on this device to log in:
https://accounts.google.com/o/oauth2/auth?client_id=563584335869-fgrhgmd47bqnekij5i8b5pr03ho849e6.apps.googleusercontent.com&scope=email%20openid%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fcloudplatformprojects.readonly%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Ffirebase%20https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fcloud-platform&response_type=code&state=842300911&redirect_uri=http%3A%2F%2Flocalhost%3A9005
Waiting for authentication...
[2025-03-10T15:31:09.297Z] >>> [apiv2][query] POST https://accounts.google.com/o/oauth2/token [none]
[2025-03-10T15:31:09.302Z] >>> [apiv2][body] POST https://accounts.google.com/o/oauth2/token [omitted]
[2025-03-10T15:31:09.818Z] *** [apiv2] error from fetch(https://accounts.google.com/o/oauth2/token, {"headers":{},"method":"POST","body":{"_overheadLength":543,"_valueLength":208,"_valuesToMeasure":[],"writable":false,"readable":true,"dataSize":0,"maxDataSize":2097152,"pauseStreams":true,"_released":true,"_streams":[],"_currentStream":null,"_insideLoop":false,"_pendingNext":false,"_boundary":"--------------------------774456112272132751061107","_events":{},"_eventsCount":1}}): FetchError: request to https://accounts.google.com/o/oauth2/token failed, reason:
[2025-03-10T15:31:09.820Z] Token Fetch Error: FirebaseError: Failed to make request to https://accounts.google.com/o/oauth2/token
at RetryOperation._fn (/home/darkreaper/.nvm/versions/node/v20.10.0/lib/node_modules/firebase-tools/lib/apiv2.js:261:31)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Authentication Error: Your credentials are no longer valid. Please run firebase login --reauth
For CI servers and headless environments, generate a new token with firebase login:ci
[2025-03-10T15:31:09.842Z] >>> [apiv2][query] POST https://auth.firebase.tools/attest [none]
[2025-03-10T15:31:09.843Z] >>> [apiv2][body] POST https://auth.firebase.tools/attest {"session_id":"0488bc1a-09e8-4374-bc7d-ea8f46f10975"}
[2025-03-10T15:31:10.856Z] <<< [apiv2][status] POST https://auth.firebase.tools/attest 200
[2025-03-10T15:31:10.857Z] <<< [apiv2][body] POST https://auth.firebase.tools/attest {"token":"jEMefqcNhsrJC0LEiByNS8ZrFqAjvarPBWTTsJuQeu0"}
To sign in to the Firebase CLI:
1. Take note of your session ID:
0488B
2. Visit the URL below on any device and follow the instructions to get your code:
https://auth.firebase.tools/login?code_challenge=1N6ynEeq4AgfXbKNiDvos3Lmn4m1kIJzQl0WB9bsQr8&session=0488bc1a-09e8-4374-bc7d-ea8f46f10975&attest=jEMefqcNhsrJC0LEiByNS8ZrFqAjvarPBWTTsJuQeu0
3. Paste or enter the authorization code below once you have it:
? Enter authorization code:
The text was updated successfully, but these errors were encountered:
Hey @alihamza0173, sorry to hear you're encountering this issue. Usually, we see this occur when there is a Firewall or proxy misconfiguration that is blocking the network request. To rule out the possibility that this is a network issue, could you try connecting to a different network or temporarily disabling VPN, Firewall, and proxy you may have?
Also, try running curl -X POST -I https://accounts.google.com/o/oauth2/token to see if you'd be able to make a request to that endpoint.
Furthermore, I had attempted logging in several times over two days, but the problem continued. Yet, I just attempted it again today, and although it failed twice, it did manage to connect successfully on the third try.
I was connected to the same network as yesterday, so there would not appear to have been any change in the network that would have influenced the result.
Please let me know if you require any additional information. Thanks!
[REQUIRED] Environment info
Firebase CLI Version: 13.33.0
Node.js Version: v20.10.0
Linux 6.12.13-amd64
[REQUIRED] Test case
Download firebase-tools or firebase-cli and authenticate from the terminal
[REQUIRED] Steps to reproduce
Execute
firebase login
,firebase login --reauth
,firebase login --no-localhost
and basically all versions of authentication available. Including ones with login:ci[REQUIRED] Expected behavior
The authentication should complete successfully within the terminal
[REQUIRED] Actual behavior
Meanwhile, the terminal outputs the following logs:
The text was updated successfully, but these errors were encountered: