Thank you so much; you are the first one who gave me a real example of what the redirect uri, as well as making many other things clear for me that I had been searching for for hours.
I am getting Error: disallowed_useragent. It tells me to use chrome or safari because it is more secure. The thing is I can't figure out how to force my app to open chrome instead of a webview inside my app. Do other people have this problem aswell?
Getting error as below under OAuthNativeFlowPage.xaml.cs Line # 47 var authenticator = new OAuth2Authenticator. During debugging I can see all the values passed to above metod Error : System.UriFormatException: Invalid URI: The format of the URI could not be determined.
Hi Bala, Do you have correct package included for OAuth2Authenticator? Are you passing your URL as string type instead of URI? Sorry I can't look at the code right now, I am traveling.
@@CuriousDrive Hi, Sorry to bother you and thanks for your time. I have downloaded the code from Github using the above link and on top of that code, I have updated my Client ID in 3 places which you have highlighted. Also, updated the package name in the Google console
Hi Curios Drive, thk so much for the tutorial it really help. Im running an issue and i create the keystore following you instructions in the video that you made the APK, but when y run the command keytool -exportcert -keystore (My keystore location) -list -v throw me an error that says The keystore file exists, but it is empty i really cant firgure out how to fixed. if you can help me i will be very grateful.
I solved it. the problem was that when i run the command in the cmd i wasnt given the ext .keystore in to "my keystore location". Example here : keytool -exportcert -keystore "C:\Users\myname\AppData\Local\Xamarin\KeystoreLocation\NameKeystore.keystore" -list -v
Hi everyone! Anybody can say me why so many videos about google authentication but no one tutorial about what to do after authentication? What is next? How to use google drive after authentication? How to download and upload file?
Thank you, it really helped me to implement , I am facing issue after successful authentication from gmail my app instance is created on the browser and I have to minimize and go to native Xamarin application there I am getting profile detail. How to remove browser instance and directly navigated to app only. I would be grateful for your suggestion. Thank you !!!
Do you have CustomUrlSchemeInterceptorActivity? I had make some changes CustomUrlSchemeInterceptorActivity to make go back to Native app. You can find this class here - github.com/CuriousDrive/PublicProjects/blob/master/OAuthNativeFlow/Droid/CustomUrlSchemeInterceptorActivity.cs I hope it works for you.
keytool -exportcert -keystore "C:\Users\USERNAME\AppData\Local\Xamarin\Mono for Android\Keystore\oauthtest1\oauthtest1.keystore" -list -v Throws the following error: keytool error: java.lang.Exception: Only one command is allowed: both -exportcert and -list were specified.
@@CuriousDrive Earlier, I was using jdk-13 but then I caught it in the video and used jdk1.8.0_221. I downloaded just that and used it. It worked perfectly. But I do not understand what is the difference.
@drew 96 I am glad that it worked for you. I am not really sure what the difference is but it looks like they have changed the syntax of the command where you can't export certificate and list all the fingerprints at the same time. Doesn't make sense, I should look into that.
Unfortunately, if you target Android 12 or above with the Xamarin.Auth package you'll get an exception: requires that one of FLAG_IMMUTABLE or FLAG_MUTABLE be specified when creating a PendingIntent. There's an open issue on the package's Github page that was created November 2021. Unfortunately, the package is no longer maintained. 🥲
If you are cloning the project then you don't need to install any nuget package but if you are starting from scratch then you need Xamarin.Auth and Newtonsoft.Json
This repo was copied from github.com/xamarin/xamarin-forms-samples and this process is fully explained on docs.microsoft.com. You should mention you are not the author.
You are correct. I should mention it. This is one of the very early videos that I made on my channel and I was not sure of what to mention in video description. Yes I am not the author but I did make some changes in the code that's why I created my own repo. I am mentioning the references the in video description now. Thanks for the feedback. :)
Thank you so much; you are the first one who gave me a real example of what the redirect uri, as well as making many other things clear for me that I had been searching for for hours.
I am glad that it was helpful. Thanks for watching the video.
After logging in with google, it is not possible to return to the application, when I manually close it, it is not logged in. What should I do?
I am getting Error: disallowed_useragent. It tells me to use chrome or safari because it is more secure. The thing is I can't figure out how to force my app to open chrome instead of a webview inside my app. Do other people have this problem aswell?
Do you have CustomUrlSchemeInterceptorActivity?
Getting error as below under OAuthNativeFlowPage.xaml.cs Line # 47 var authenticator = new OAuth2Authenticator. During debugging I can see all the values passed to above metod
Error :
System.UriFormatException: Invalid URI: The format of the URI could not be determined.
Hi Bala, Do you have correct package included for OAuth2Authenticator? Are you passing your URL as string type instead of URI?
Sorry I can't look at the code right now, I am traveling.
@@CuriousDrive Hi, Sorry to bother you and thanks for your time. I have downloaded the code from Github using the above link and on top of that code, I have updated my Client ID in 3 places which you have highlighted. Also, updated the package name in the Google console
Hi, Any luck on the above error?
Hi, it works but says account store is obselete. do you know how I can use xamarin secure storage instead?
I would also like to know that
@@mapelpapel1998 I managed to find a way around that.... By migrating to secure storage
Hi Curios Drive, thk so much for the tutorial it really help.
Im running an issue and i create the keystore following you instructions in the video that you made the APK, but when y run the command
keytool -exportcert -keystore (My keystore location) -list -v throw me an error that says The keystore file exists, but it is empty i really cant firgure out how to fixed. if you can help me i will be very grateful.
I solved it. the problem was that when i run the command in the cmd i wasnt given the ext .keystore in to "my keystore location".
Example here :
keytool -exportcert -keystore "C:\Users\myname\AppData\Local\Xamarin\KeystoreLocation\NameKeystore.keystore" -list -v
Good Job Luis, and thanks for sharing information with the community.
what is the difference between this and firebase google login auth?
I hope this helps. stackshare.io/stackups/firebase-authentication-vs-oauth2
Google Sign-in description is useful, of couse... But how about getting list of files from Google Drive? ;)
Not sure if you have already checked out this link or not - developers.google.com/drive/api/v3/quickstart/dotnet
Join this question
@@CuriousDrive the link describes how to use API Google Drive for JavaScript and for Web Application but not for .Net and Mobile application.
How to get the "access token" after google authentication in xmarine android?
I am doing this on my Mac an cannot find the URL file he goes to later in the video
@Curious Drive its the points where you start editing files that i cannot find
I am making changes in Constants.cs file which is in the core project.
Thanks for watching the video. Please don't forget to subscribe and share
Hi everyone! Anybody can say me why so many videos about google authentication but no one tutorial about what to do after authentication? What is next? How to use google drive after authentication? How to download and upload file?
helpful.. but fyi xamarin essentials gives you great alternates to Application.Current.Properties
Thanks Neville, I see it's documentation at docs.microsoft.com/en-us/xamarin/essentials/preferences?tabs=android
Thank you, it really helped me to implement , I am facing issue after successful authentication from gmail my app instance is created on the browser and I have to minimize and go to native Xamarin application there I am getting profile detail. How to remove browser instance and directly navigated to app only. I would be grateful for your suggestion. Thank you !!!
after signin the page stays on Google Home page does not return to Native App
Do you have CustomUrlSchemeInterceptorActivity?
I had make some changes CustomUrlSchemeInterceptorActivity to make go back to Native app.
You can find this class here - github.com/CuriousDrive/PublicProjects/blob/master/OAuthNativeFlow/Droid/CustomUrlSchemeInterceptorActivity.cs
I hope it works for you.
@@CuriousDrive It works like a charm for me! Thank you so much!
how to hide status bar and navigation bar on a specific page(activity) in xamarin forms???
Hi Muhammad, I haven't personally tried this solution but maybe you can try this
stackoverflow.com/a/36659418/12014626
@@CuriousDrive sir that hides only navigation bar.. i also want to hide status bar..
Looks like very hard thing to implement but possible
stackoverflow.com/a/36451267/12014626
@@CuriousDrive Thank you...
@@muhammadtayyab2004 You are welcome. I would really appreciate if you subscribe my UA-cam channel and share it your friends too :)
keytool -exportcert -keystore "C:\Users\USERNAME\AppData\Local\Xamarin\Mono for Android\Keystore\oauthtest1\oauthtest1.keystore" -list -v
Throws the following error:
keytool error: java.lang.Exception: Only one command is allowed: both -exportcert and -list were specified.
Hey, what version of java runtime are you using?
@@CuriousDrive Earlier, I was using jdk-13 but then I caught it in the video and used jdk1.8.0_221. I downloaded just that and used it. It worked perfectly. But I do not understand what is the difference.
@drew 96 I am glad that it worked for you. I am not really sure what the difference is but it looks like they have changed the syntax of the command where you can't export certificate and list all the fingerprints at the same time. Doesn't make sense, I should look into that.
Unfortunately, if you target Android 12 or above with the Xamarin.Auth package you'll get an exception: requires that one of FLAG_IMMUTABLE or FLAG_MUTABLE be specified when creating a PendingIntent. There's an open issue on the package's Github page that was created November 2021. Unfortunately, the package is no longer maintained. 🥲
Also what packages do we need downloaded
@Curious Drive what package did you install into your nuget ?
If you are cloning the project then you don't need to install any nuget package but if you are starting from scratch then you need Xamarin.Auth and Newtonsoft.Json
For login with gmail for ios what are the steps to be follow
Hello Techpro, I don't have a mac machine so I couldn't test and add that to the demo.
@@CuriousDrive Ok thanks.
Dude, thanks.. you save my ass.. ❤
Subscribe now..
Thanks for watching PleuralBlue. Please share with your friends too.
This repo was copied from github.com/xamarin/xamarin-forms-samples and this process is fully explained on docs.microsoft.com. You should mention you are not the author.
You are correct. I should mention it. This is one of the very early videos that I made on my channel and I was not sure of what to mention in video description. Yes I am not the author but I did make some changes in the code that's why I created my own repo.
I am mentioning the references the in video description now. Thanks for the feedback. :)
Hi Thank you fro the Good login can you give me the Facebook all so
Check out this video - ua-cam.com/video/Mq3us6CG9TY/v-deo.html
I hope that was helpful. Don't forget to subscribe
After logging in with google, it is not possible to return to the application, when I manually close it, it is not logged in. What should I do?