firebase-authentication

How to get Firebase UID knowing email user?

霸气de小男生 提交于 2021-02-11 13:17:35
问题 I am building a Flutter app where the administrator profile can create users to access their company. The code works right, unless the new user was previously created for another company. In this case an error of type ERROR_EMAIL_ALREADY_IN_USE appears from FIREBASE AUTH. What I want to do is simply retrieve the assigned UID from FIREBASE AUTH, which is necessary to assign the user within my database to an additional company. It's my code... _register(LoginBloc bloc, BuildContext context)

How to increase Firebase Authentication Session Time using Flutter?

别说谁变了你拦得住时间么 提交于 2021-02-11 12:30:14
问题 I developed an Agro App and I have enabled offline persistence because, after logging in, operators can spend 3-4 hours recording information offline until they return to the central point where there is internet. The problem I have is that sometimes the application asks for credentials (login and password) again when they do not have internet, which means that they cannot record information offline or they have to go back to the central point to authenticate which is not efficient. I

Remove First name & last name field from firebase auth - email

久未见 提交于 2021-02-11 12:20:14
问题 I am using firebase auth for my website i have enabled Google, facebook & Email based auth everything works fine, But when using Email login Users are required to enter Firstname But i don't need these details and want to keep the user login / signup process short Question : Can we remove the First & Lastname fields from firebase auth email 回答1: From the documentation it seems you can toggle the requirement to enter a name with requireDisplayName . From that link comes this example: ui.start(

Can I get a facebook access token from firebase.auth().currentUser?

安稳与你 提交于 2021-02-11 12:15:06
问题 First after I login facebook via firebase auth as below let provider = new firebase.auth.FacebookAuthProvider() firebase.auth().signInWithPopup(provider).then((result)=>{ console.log(result) }) I found a facebookAccessToken (which I will use for graphAPI) in result but after I refresh a page , when a page did mount I call a function as below let currentUser = firebase.auth().currentUser console.log(currentUser) I can't found a facebookAccessToken in currentUser Can I get a facebookAccessToken

In firebase by using email and password authentication, i want to additional user data using push

耗尽温柔 提交于 2021-02-11 09:58:55
问题 I am using firebase as my backend. Users are authenticating using Email and Password. I'm storing additional data such as name and phone in the realtime database using push. How do i retrieve user data to display on the user profile since a uniqueid is generated. Here is the activity in which i'm storing the data public class UserActivity extends AppCompatActivity { private EditText inputName, inputPhone, inputNatId,inputDOB; private TextInputLayout inputLayoutName, inputLayoutPhone,

FirebaseAuth.getInstance().signOut() doesn't signout

眉间皱痕 提交于 2021-02-11 08:12:03
问题 I try to signout user from firebase but after i close my app and open again the user is stills connect I tried the regular signout of user from firebase and it not solve the problem. I am wondering what could cause the problem logout.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { FirebaseAuth.getInstance().signOut(); Intent picture_intent = new Intent(Dashboard.this,LoginActivity.class); startActivity(picture_intent ); } }); my check if user connect:

firebase security rule to allow admin users to read/write all other users creates a security breach?

元气小坏坏 提交于 2021-02-11 05:57:30
问题 I am using cloud Firestore database and I have 'users' collection on my root database and in it there are all the users documents (named as the uid) and inside it the data I collect. I wanted to allow users to only read/write to their own collections so I started my security rules with service cloud.firestore { match /databases/{database}/documents { // Allow only authenticated content owners access match /users/{userId}/{documents=**} { allow read, write: if request.auth.uid == userId } } }

firebase security rule to allow admin users to read/write all other users creates a security breach?

泪湿孤枕 提交于 2021-02-11 05:55:40
问题 I am using cloud Firestore database and I have 'users' collection on my root database and in it there are all the users documents (named as the uid) and inside it the data I collect. I wanted to allow users to only read/write to their own collections so I started my security rules with service cloud.firestore { match /databases/{database}/documents { // Allow only authenticated content owners access match /users/{userId}/{documents=**} { allow read, write: if request.auth.uid == userId } } }

Swift - Firebase Auth with Microsoft Graph (Redirect URL Problem)

假如想象 提交于 2021-02-10 20:40:42
问题 I'm having a problem integrating Firebase with Microsoft Auth in my iOS App. The login page has been launched and I can sign in by Office365 account but login auth can not be finished because of the below Error : "AADSTS50011: The reply url specified in the request does not match the reply urls configured for the application:[app-id]" I did check the setting in Firebase and below are the settings I add in the app of Azure Active Directory : Web redirect URL : "*.firebaseapp.com/__/auth

Swift - Firebase Auth with Microsoft Graph (Redirect URL Problem)

烂漫一生 提交于 2021-02-10 20:37:53
问题 I'm having a problem integrating Firebase with Microsoft Auth in my iOS App. The login page has been launched and I can sign in by Office365 account but login auth can not be finished because of the below Error : "AADSTS50011: The reply url specified in the request does not match the reply urls configured for the application:[app-id]" I did check the setting in Firebase and below are the settings I add in the app of Azure Active Directory : Web redirect URL : "*.firebaseapp.com/__/auth