-1

Is it save to expose firebase cloud messaging server key (legacy) and sender id in client js code ? If an attacker gain access to those keys what damage can attacker do ?

ReyAnthonyRenacia
  • 17,219
  • 5
  • 37
  • 56
mohammad obaid
  • 415
  • 4
  • 16

1 Answers1

0

As the name of the key already implies, the FCM server key should only be used on a server (or an otherwise trusted environment, such as Cloud Functions). Anyone who has this key can send messages to all users of your app.

Frank van Puffelen
  • 565,676
  • 79
  • 828
  • 807