How to solve restricted_client error in google sign in flutter IOS? - flutter

I'm trying to implement google signin in my flutter app when I click google-signin button.
when I click continue it redirects to a browser window and tells
I have enabled google sign in and place json file in correct path
can any one help?

Clicking on 'Learn More' in the error message above should take you to the Google Cloud Console configuration for your project, where you need to configure the OAuth consent screen information before you can use Google Sign In.
If you already know your Google Cloud project information, visiting https://console.developers.google.com/apis/credentials/consent will take you to the consent screen configuration.
You can find more information at https://support.google.com/googleapi/answer/6158849?hl=en.

Related

How to show google accounts dialog in flutter?

I want to do the login/signup process with google acc in the flutter application. Our backend developer gives me an API to call that and get a link for choosing a google account. That link is like this:
https://accounts.google.com/o/oauth2/v2/auth?redirect_uri=https%3A%2F%2Fapi-v1-dare.cloud.atadp.ir%2Fapi%2Fauth%2Flogin%2Fgoogle%2Fcallback&client_id=1039193858277-2vkeh4q5nvi69bdfe4sr44boo0itlau5.apps.googleusercontent.com&access_type=offline&response_type=code&prompt=consent&scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.profile+https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fuserinfo.email
When I open this link in my browser, I can choose a google account:
And when choose account, I get this data:
I try to use the google_sign_in package but can't find a way to load that link. Can you help me how to do this process?

Ionic 4, Azure Active Directory B2C in with Google as identity provider

this topic is about the combination of Ionic 4 + Capacitor + Azure Active Directory B2C + Native Application
I am working inside an Ionic 4 project and i am using Azure Active Directory B2C as login provider.
Unfortionally, trying to add Google as login provider leads to the following problem:
https://azure.microsoft.com/de-de/blog/azure-ad-b2c-google-signin-issue/
Google does not support webviews anymore.
Is there any way to open the login mask from Azure B2C with the embedded browser and only the external Google login with an external browser? I feel like i am forced to open the whole login process with the system browser if I want to use the google login service, which is no option because of the missing option in hiding the URL bar for that external browser.
Because I need a way in open the login mask without the toolbar. The page should look like a clean login mask, so the user does not get the feeling of leaving the application.
Did anyone experience this issue before and found a way in solving it? What I want is the following behaviour:
From the native app the user should be able to open the login mask from Azure and feel like not leaving the app. So this login mask should be opened inside an webview or inapp browser because I think there is no way in manipulating the system browser to hide the URL bar.
Then, if the user decides to use the google identy provider to login, the system browser can be used, best would be inside a pop up window
I would appreciate if someone has a solution for this problem.
Best regards

Flutter Google Sign In - This App isn't verified error

I'm getting a 'This app isn't verified' error when I use the Flutter google_sign_in plug in. I want to get authorisation to Google Drive so added it to the google sign-in scope:
scopes: ['email', 'https://www.googleapis.com/auth/drive'],
And it is the request for the drive scope that is causing the error screen to come up ( I tested it with just email and works fine).
If I look at the docs it seems that Google are saying I have to verify the app, however this is a test app to see if I can get the functionality that a client has requested working with Google Drive and won't ever be promoted.
Does anyone know how I can remove this error message for test purposes only?
Many thanks
Here's the actual screen with the error:
The above warning shows when the app isn't verified. Google consents user that the app is not verifed yet and you are sharing sensitive data to it.
We can proceed and complete our flow by clicking the Advanced at bottom left. Once app is verfied this warning will be removed automatically.
Anyone can follow instruction listed on here
https://support.google.com/cloud/answer/7454865?hl=en

Error 403 Restricted Client with Google Signin in Flutter

I've setup firebase_auth and google_signin about 6 times, but in my latest app I must have forgotten a step.
firebase_auth: ^0.11.1
google_sign_in: ^4.0.1+3
When the Google Login page should appear I instead get a webpage that says 403 Error Restricted Client. Further down it says This app is not yet configured to make OAuth requests.
1) I've update the GoogleService-Info.plist file.
2) I've added the section CFBundleURLTypes section to Info.plist file.
3) I've enabled Google auth in my Firebase project.
What did I forget?
In my case I forgot to set support e-mail address in Google Developers Console > API and service > certificate > OAuth consent screen link and this option also in your Firebase project setting. After set up everything is working.
I set the support e-mail address and the LOGO in Google :
Developers Console > API and service > Credential > Oauth Consent Screen.
After this set up all is working.
To fix a similar issue I had to add the email I am logged in with to google as a test user:
Go to https://console.developers.google.com/
On the top right ensure that your using the correct developer account
On the top left next to the words "Google Cloud Platform" ensure that you are on the correct project
In the search bar, look for "oauth consent screen" and click on it
Created a consent screen if you didn't before now
Under "Test users" click "+ADD USERS"
Add the email account(s) you will be testing with and save.
It should work now!
Had a similar problem with an angular project. The solution was indeed to set a support email address in the firebase console project settings under the general tab.
This is crazy, it didn't work even after I setting support email. But once I uploaded the logo image, it works.
Go to the link showing in error page, and set both logo and email.

Sign in with google in my website

I have created Client Id in google console, and I put the code given in google console,
but if I have already signed in gmail in other tab, and I open my website it automatically sign in with gmail.
I want to know that how can I implement this so that when user press 'Sign in with google' then only it goes to other page.
I am also having that issue. I think if we use a javascript onclick function, that should work. But have you got any solutions yet?