Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dangerous placement of the Firebase configuration #22

Open
TheLukaszNs opened this issue Nov 4, 2018 · 0 comments
Open

Dangerous placement of the Firebase configuration #22

TheLukaszNs opened this issue Nov 4, 2018 · 0 comments

Comments

@TheLukaszNs
Copy link

Firebase configuration is placed in the index.html file and is publically visible not only to the end user but also for all people visiting this repo:

<script>
  // Initialize Firebase
  var config = {
    apiKey: "AIzaSyCv0ELrK-dnBDHNABwtbs22o8UAaAE_FC0",
    authDomain: "openpub-41be7.firebaseapp.com",
    databaseURL: "https://openpub-41be7.firebaseio.com",
    projectId: "openpub-41be7",
    storageBucket: "openpub-41be7.appspot.com",
    messagingSenderId: "624812372332"
  };
  firebase.initializeApp(config);
</script>

Malicious user can use this config (apiKey, messagingSenderId, etc.) to perform rather dangerous operations to the app.
We should export this to another file and add its path to the .gitignore file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant