firebase-authentication

Firebase simulate read denied

懵懂的女人 提交于 2019-12-11 15:14:54
问题 In my firebase project, I have implemented Google Authentication. My firebase rules looks like the following: { "rules": { "users": { "$uid": { ".read": "auth.uid == $uid", ".write": "auth.uid == $uid" } } } } The database has the following snapshot: Everytime I try to simulate. Firebase says that the "Simulate read denied". Any ideas that I am doing wrong here? 回答1: I realised the problem. I was accessing "/users" but instead, I should be accessing "/users/$uid" to simulate rule. 来源: https:/

How to create a Firestore safe Document ID based on a string

末鹿安然 提交于 2019-12-11 15:12:56
问题 After some discussion on my question about base64 not being safe for Firestore IDs here I would like to know how one can encode a string to a Firestore "safe" Document ID. Here is the problem: I am login in users via a custom authentication service. That service provides a username that can contain / that are not safe for the firestore document ids as declared here I asked about the base64 in another question and that is not safe as it contains / So what could be a safe way to encode that

How to count users from Firebase with PHP (Laravel 5.8)

强颜欢笑 提交于 2019-12-11 15:07:55
问题 I'm trying to figure out how to count all registered users from the Firebase. I've only implemented the Firebase authentication and have not mannualy created a database. I can't find a way to count or even get them from Firebase. $serviceAccount = ServiceAccount::fromJsonFile(config_path('path-to-file.json')); $firebase = (new Factory()) ->withServiceAccount($serviceAccount) ->create(); $database = $firebase->getDatabase(); I've got a connection with the code above. Also I tried to use the

How to make Android Google Sign In button to just Login and not register with FirebaseAuth?

痴心易碎 提交于 2019-12-11 14:54:09
问题 I have a Login activity with the option to type your email & pass and then login through FirebaseAuth , but it also have a Google Sign In button . When I click it and I choose an account that have been already registered everything is correct. BUT when I click on an account that is not in my Firebase Authentication it's get created ! I have implementing it looking at the official documentation (My code is like in the doc so no need to copy it here) What I want is when I click on an account

How to verify email without the need of signing in again while using FirebaseUI-auth?

梦想与她 提交于 2019-12-11 14:40:41
问题 I'm using FirebaseUI-auth in my app in order to sign in user using email and facebook. When a user signin using email he is taken to a screen which shows a text asking him to verify his email. Here's my code: continue_button.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { startActivityForResult( // Get an instance of AuthUI based on the default app AuthUI.getInstance() .createSignInIntentBuilder() .setProviders(Arrays.asList(new AuthUI.IdpConfig

PlatformException(sign_in_failed, com.google.android.gms.common.api.ApiException: 10: , null) when using Flutter to build an appbundle

南笙酒味 提交于 2019-12-11 14:29:43
问题 I'm building a Flutter app with firebase_auth and google_sign_in. Everything was working well for a while and all of my existing users on the released product have not experienced any problems, but a while back I started getting reports that new users couldn't log in. I didn't think much of it until the reports started to accumulate. I found that they were getting the error posted in the title. I spent a ton of time investigating... I've gone through all of the other StackOverflow entries for

Trouble with user registration in Firebase

空扰寡人 提交于 2019-12-11 14:28:06
问题 I've successfully connected to firebase and added all required dependencies but i am unable to register users into it.The code I wrote is in this picture I've also provided the gradle dependencies list please check where i am going wrong The code I've written I've enabled email and password verification in firebase yet it doesnt work. Here is the list of my dependencies. dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) implementation 'com.android.support:support-v4:28.0

Cannot catch auth/email-already-in-use when Updating Email

淺唱寂寞╮ 提交于 2019-12-11 14:23:28
问题 I'm having a problem with the function to update the user email. The function does three main things. First, it changes the email to the Firebase Auth, then it updates the email in the database, and last it sends the email verification. I'm able to catch the incorrect password error, but when it comes to auth/email-already-in-use error, it doesn't work. The problem is that I'm updating the email in the database and sending the verification email, but it's not updating the email in Firebase

Firestore rule to read collection

自古美人都是妖i 提交于 2019-12-11 14:18:50
问题 Firestore rule to read collection overrides document rule to deny unauthorized access of other users data. Here's my scenario, I'm getting the user information with the phone number associated by the Authentication and the Document in the database. I'm querying the whole /users collection with where clause and in the Firestore Rules I'm letting anyone to read /users collection, but I think this is insecure. Javascript const phone_number = firebase.auth().currentUser.phoneNumber // Example: "

Firebase / angularFire2 v5 authentication issue on mobile

这一生的挚爱 提交于 2019-12-11 14:16:31
问题 I am creating a PWA and trying to use firebase/angularfire2 v5 to authenticate my users against Facebook or Google (I followed a tutorial that is present in angularfire2 github site). When I use the application in a "normal" browser in a desktop or mobile device everything works fine. The problem starts when I install the application in a mobile device and try to use the authentication (in the manifest.json the property display is set to "standalone"). I end up in a blank page. I tried to