Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[.NET MAUI] How implement "OpenBrowserAndWaitForRedirectToAuthDomain" #208

Open
eliasribeiro opened this issue Oct 27, 2023 · 5 comments
Open

Comments

@eliasribeiro
Copy link

How to implement the method in "OpenBrowserAndWaitForRedirectToAuthDomain" in .NET MAUI?

Because the Launcher and Browser classes only open the browser and do not have resources to monitor the situation and obtain any positive or negative response from the Browser Login.

With WebView I was also unable to be successful, as at the end of Login it returns the message "Unable to process the request due to lack of initial state. This can happen if the browser's sessionStorage is inaccessible or accidentally deleted." I don't know how to resolve this message or how to wait for the success/failure process to then return a value in the SignInRedirectDelegate of SignInWithRedirectAsync.

Unfortunately we also don't have any example projects with this implementation for .NET MAUI.

@bezysoftware
Copy link
Collaborator

@eliasribeiro
Copy link
Author

Microsoft's authentication solution requires ASP.NET application hosting and does not work for Firebase.

@osyyyS
Copy link

osyyyS commented Jul 26, 2024

@eliasribeiro Hi, did you find a solution by any chance?

@MaxGuernseyIII
Copy link

@osyyyS

@eliasribeiro Hi, did you find a solution by any chance?

It's the link @bezysoftware sent. There's zero evidence it requires ASP.NET hosting. It explicitly says it works via redirects. Maybe in October of 23, that was not the case, but it is, now.

https://learn.microsoft.com/en-us/dotnet/maui/platform-integration/communication/authentication?view=net-maui-8.0

The misinterpretation could be from this passage:
image

...but all that's saying is that the authority for authentication should not be the mobile app, such as might be the case with Firebase.

I'm sure it's too late to help you, @osyyyS, but I wanted to record this for the next guy who spent a frustrated week looking for a meaningful, functional cross-platform Firebase authentication solution, like I just did.

I've finally found what I need, in this package, and I hope the next guy doesn't have to search so hard to find it.

@MaxGuernseyIII
Copy link

I take back that last bit paragraph. I still haven't gotten this package working for me on a MAUI app.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants