firebase / firebase/firebase-js-sdk

Firefox error on signInWithCustomToken with empty referer: auth/requests-from-referer-<empty>-are-blocked

Open
#8,417 6 comments 0 reactions 0 assignees View on GitHub
api: auth needs-attention question stack:Vue
Dominant language
TypeScript
Stars
5.1k
Forks
1k
Avg merge
2d 21h
Merged PRs (30d)
37

Description

### Operating System

Mac M1, macOS 14.5

### Browser Version

Firefox 129.0

### Firebase SDK Version

10.12.5

### Firebase SDK Product:

Auth

### Describe your project's tooling

Vue + Vite building a browser extension

### Describe the problem

When making a call to `signInWithCustomToken`, Firebase auth receives an HTTP 403 from the identity endpoint with the following error:

![image](https://github.com/user-attachments/assets/010d5c34-7a6b-42ae-9236-af9da03f8dca)

This only occurs in Firefox and works as expected on Chrome.

![Screenshot 2024-08-06 at 10 29 28 PM](https://github.com/user-attachments/assets/40a8b575-c80f-447a-8ba5-9bff524914a7)

### Steps and code to reproduce issue

I have the code published in the following extensions (with minimal obfuscation):

Chrome version of the extension where everything works: https://chromewebstore.google.com/detail/turasapp/lpfijfdbgohlblnadiokliolkkeeblpo

Firefox version: https://addons.mozilla.org/en-US/firefox/addon/turas-app/

There is no functional difference in the output code.

May be related to this issue: https://github.com/firebase/firebase-js-sdk/issues/7997

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.