firebase-authentication

Firebase Storage Rules with Custom Claims

一个人想着一个人 提交于 2019-12-19 10:17:16
问题 I am unable to get Firebase Storage work with custom rules and using custom claims. In my Python Admin panel, I do the following to create the user and assign a claim client_id: # Standard Auth import firebase_admin from firebase_admin import db, storage, auth cred = firebase_admin.credentials.Certificate('path_to_cert_json') app = firebase_admin.initialize_app(cred, 'config') bucket = storage.bucket(app=app) # Create User auth.create_user(email=email) # Create custom claims auth.set_custom

Is there any function in User Authentication for User Roles?

一笑奈何 提交于 2019-12-19 09:48:08
问题 I'm trying to make a login interface for my web app using Firebase. I wanted to add a user role to my account using Firebase's own Authentication System. (Email). But it does not support any options for adding a user role . Such as "Admin" and "Users". This is for Firebase (currently 5.7.2), and HTML5. login.js (current login authentication) (function(){ var ui = new firebaseui.auth.AuthUI(firebase.auth()); var uiConfig = { callbacks: { signInSuccessWithAuthResult: function(authResult,

firebase auth not work with PWA installed on Android desktop

不问归期 提交于 2019-12-19 09:06:36
问题 I have built a SPA that works in the browser in that on load it provides an auth option, I click google signin and the firebase auth flow continues until I have an auth token etc. I can then switch the PWA and use as normal. But if I then logout, I cannot log back in again with the App using Google Auth - whether I let the google signin popup run in the App or in Chrome, no confirmation ever gets abck to the App and indeed it seems to crash. The issue has something to do with the loading of

firebase auth not work with PWA installed on Android desktop

荒凉一梦 提交于 2019-12-19 09:06:16
问题 I have built a SPA that works in the browser in that on load it provides an auth option, I click google signin and the firebase auth flow continues until I have an auth token etc. I can then switch the PWA and use as normal. But if I then logout, I cannot log back in again with the App using Google Auth - whether I let the google signin popup run in the App or in Chrome, no confirmation ever gets abck to the App and indeed it seems to crash. The issue has something to do with the loading of

How to access current firebase user from iOS Today Extension?

你说的曾经没有我的故事 提交于 2019-12-19 08:27:32
问题 We're building a today widget on top of our iOS app which is working with Firebase. However we're struggling to access current signed-in user from the extension. The user at the main app is anonymous so passing credentials via shared container is not an option. The only way that I found is passing uid and generate custom token to sign in but I was hoping to find out better way to share FIRUser between my main app and app extension. What would be the best way to achieve this? 回答1: You can

Firebase phone Auth for Android , Can we just verify phone number without creating a user account

不羁岁月 提交于 2019-12-19 07:51:13
问题 I am working on an android app, in where I just want to verify mobile number without creating a user account. Is it Possible? I am using the following code private void startPhoneNumberVerification(String phoneNumber) { PhoneAuthProvider.getInstance().verifyPhoneNumber( phoneNumber, // Phone number to verify 60, // Timeout duration TimeUnit.SECONDS, // Unit of timeout this, // Activity (for callback binding) mCallbacks); // OnVerificationStateChangedCallbacks } private void

Not getting the email using Google Authentication in Firebase

自作多情 提交于 2019-12-19 06:31:51
问题 I am using the code provided by Firebase for Google Authentication and somehow, the authentication was successful but the email was not correctly imported to Firebase. https://firebase.google.com/docs/auth/ios/google-signin As you can see in the screenshot below, the email is blank. When I looked at the debugger, it is showing nil. I clicked allow viewing email during authentication but I think there are still some settings that was not done correctly. Could someone help me to take a look? I

Not getting the email using Google Authentication in Firebase

限于喜欢 提交于 2019-12-19 06:31:16
问题 I am using the code provided by Firebase for Google Authentication and somehow, the authentication was successful but the email was not correctly imported to Firebase. https://firebase.google.com/docs/auth/ios/google-signin As you can see in the screenshot below, the email is blank. When I looked at the debugger, it is showing nil. I clicked allow viewing email during authentication but I think there are still some settings that was not done correctly. Could someone help me to take a look? I

How to update both Email and Password with new Firebase in swift

本小妞迷上赌 提交于 2019-12-19 06:24:15
问题 I'm developing app with new firebase from google. And I'm having problem with updating user email and password. Here's what I've tried. let currentUser = FIRAuth.auth()?.currentUser currentUser?.updateEmail(email) { error in if let error = error { print(error) } else { // Email updated. currentUser?.updatePassword(password) { error in if let error = error { } else { // Password updated. print("success") } } } } But when updating password this occurs error like this. "Domain=FIRAuthErrorDomain

How to update both Email and Password with new Firebase in swift

最后都变了- 提交于 2019-12-19 06:22:34
问题 I'm developing app with new firebase from google. And I'm having problem with updating user email and password. Here's what I've tried. let currentUser = FIRAuth.auth()?.currentUser currentUser?.updateEmail(email) { error in if let error = error { print(error) } else { // Email updated. currentUser?.updatePassword(password) { error in if let error = error { } else { // Password updated. print("success") } } } } But when updating password this occurs error like this. "Domain=FIRAuthErrorDomain