Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Firebase Auth Emulator interferes with Firebase Storage

Aperta
#769 0 commenti 1 reazione 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
java

Direzione di ricerca

Inizia leggendo src/main/java/com/google/firebase/auth/internal/Utils.java e src/main/java/com/google/firebase/ImplFirebaseTrampolines.java, prestando particolare attenzione alla gestione di FIREBASE_AUTH_EMULATOR_HOST e delle credenziali dell'emulatore. Riproduci il problema con Auth e Storage abilitati insieme, quindi verifica che le chiamate a Storage rimangano autorizzate mentre le credenziali dell'emulatore vengano applicate solo ad Auth; verifica inoltre se istanze separate di FirebaseApp possano avere configurazioni dell'emulatore diverse.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

api: auth
[READ] Step 1: Are you in the right place?
  • For issues or feature requests related to the code in this repository
    file a Github issue.
    • If this is a feature request make sure the issue title starts with "FR:".
  • For general technical questions, post a question on StackOverflow
    with the firebase tag.
  • For general Firebase discussion, use the firebase-talk
    google group.
  • For help troubleshooting your application that does not fall under one
    of the above categories, reach out to the personalized
    Firebase support channel.
[REQUIRED] Step 2: Describe your environment
  • Operating System version: Windows 11
  • Firebase SDK version: ____
  • Library version: 9.1.1
  • Firebase Product: auth, storage
[REQUIRED] Step 3: Describe the problem

We access the Auth and Storage services in our project using this Java Admin SDK.
Recently, we wanted to make use of the Auth Emulator for development purposes. However, after enabling the emulator by setting the FIREBASE_AUTH_EMULATOR_HOST environment variable, the Storage calls stop working and return 401 Unauthorized.

It seems that by setting the FIREBASE_AUTH_EMULATOR_HOST environment variable, the whole project enters an emulator mode and uses emulator credentials. The emulator credentials should be made to only apply to Auth calls.

Furthermore, I could not even find a way to create two instances of FirebaseApps (one with the emulator enabled and one disabled), since the check for FIREBASE_AUTH_EMULATOR_HOST is static and shared program-wide.

Steps to reproduce:

Use Auth and Storage in a production project. Enable FIREBASE_AUTH_EMULATOR_HOST and Storage stops working.

Lingua principale
Java
Stelle
620
Fork
305
Merge medio
4g 9h
PR unite (30g)
4

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di firebase/firebase-admin-java

Tutte le issue di firebase/firebase-admin-java

Issue simili

Altre issue su Java

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.