How to ensure security when storing the server token client side? #186
Answered
by
TheAlphamerc
ScottLee97
asked this question in
Q&A
|
Hi @TheAlphamerc , thank you once again for sharing this project. I'm looking to implement a firebase REST API for the FCM notification like yours. But I noticed that you have included the FCM server key in the client-side code. Wouldn't it be a security risk, as malicious users can get that key and send any message they want to all of the users? Is there a way to ensure the security of the server token?? Or is using the cloud function to send the notification the only way to make it more secure ?? Thank you in advance! |
Answered by
TheAlphamerc
Jun 24, 2021
Replies: 1 comment 4 replies
|
Storing FCm server kry on client side is not a good approach. There is one way to keep it secure if it can be stored at server side. Using the cloud functions to send notification is definitely a good approach. |
4 replies
Answer selected by
ScottLee97
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Storing FCm server kry on client side is not a good approach. There is one way to keep it secure if it can be stored at server side. Using the cloud functions to send notification is definitely a good approach.