I want to login in my iOS App with a Google account. Instead of having a database with users and having to register all the users, I simply login with my existing Google account.
Anyone knows a way of doing this, or a tutorial?
Google Accounts Authentication and Authorization for Mobile Apps has fairly detailed instructions for authenticating Google account users and includes iOS-specific steps.
Related
I'm using google authentication to sign in with firebase.
The authentication process works well and I'm able to create the credentials and authenticate.
My problem is when, after signing out from firebase and google, the user tries to sign in using google again. At this point google will automatically authenticate with the account used previously.
I tried both sign-out and disconnect option from google api but the result is the same.
I partially found what my problem was, here steps to reproduce:
Not signed in with google in app and not signed-in in safari on the device with a google account
Sign in with the application using a google account
Now I am signed-in in app AND in safari as well with the same account
When I sign-out from the application, safari is still authenticated with this user
I'm not able to see the account choice in app until I sign-out the google account from safari on the device
This problem doesn't show up if safari (point 1) was already signed-in with a different google account. In this case I will always have a choice between the two accounts in app.
Is there a way to sign out from the app and always shows the account choice when signing in with google again?
There are many Authentication URI parameters. One of them is "prompt" which could have a "select_account" value. It helped me to resolve the same issue for Auth0-service Google integration. Maybe could be useful for your issue if the SDK allows setting parameters for sign in.
See docs here: https://developers.google.com/identity/protocols/OpenIDConnect#authenticationuriparameters
I have integrated the google sign in sdk in ios but I forgot from which account I did it.
I have the configuration file and client id and reverse client id
So how can I know which google account I used to create an sign in.
For getting user details of logged in user you can use this API
https://www.googleapis.com/gmail/v1/users/me/profile
for more details refer this link
I'm creating an SDK which provides features that the official app uses. I want to enable oAuth login like Facebook. If a user signs up with Facebook in the official app, how can I have them log in to the same account from via the SDK that is integrated in another app?
Would I share the same access token across the SDK to all clients that implement it? Or is there a way to be able to allow the user to sign in via oAuth into an account that they created through the official app? My current thought is that we pull some ID (e.g. email address) and do a lookup to see if that email address exists in our database and work from there (which could be a pain if the user changes their email address).
Thank you
Is it possible to authenticate a user to post to any Twitter or Facebook account from their iOS app? By this I mean not an account thats set it your Settings App. I'm hoping it can be done with their new iOS Social Framework as I know the Twitter and Facebook APIs will not always be supported.
I want to be able to enter the credentials of any user and make a post as them.
Your questions is kind of unclear, but it comes down to this: As an app developer, you are only allowed the permissions to the social account that the user is logged into inside of the settings app (and only after the user grants the app permission).
For the iOS social framework, the user is allowed to be simultaneously logged into multiple Twitter accounts, except only one Facebook account.
Read up on the Social.framework here: Social.framework
And the facebook open graph api here: Facebook Open Graph
I have completed my iOS app and now want to have user registration and authentication functionality.
When the user opens the app it must ask them to register or login and then when the app closes it logs out. I want to send their basic details to my server e.g. name, location.
Is this allowed my Apple and does anyone know of a service that I could use as appose to reinventing the wheel?
It is allowed by Apple.
There are apps on App Store that do not implement their own register/login mechanism. Those apps ask their users to login via Facebook. So any user who has a Facebook account, can login to your app using their FB credentials. You would have to use the iOS SDK provided by Facebook.
It is always better to provide multiple login options to your app user, instead of just relying on Facebook or any other provider. Allow users to login via GMail, for example.
Adding support for OpenID is another good option. OpenID is an open standard that describes how users can be authenticated in a decentralized manner, eliminating the need for services to provide their own ad hoc systems and allowing users to consolidate their digital identities. Users may create accounts with their preferred OpenID identity providers, and then use those accounts as the basis for signing on to any website which accepts OpenID authentication.