auth0-flutter icon indicating copy to clipboard operation
auth0-flutter copied to clipboard

Desktop support

Open Sesa1988 opened this issue 1 year ago • 20 comments

Checklist

  • [X] I have looked into the README and have not found a suitable solution or answer.
  • [X] I have looked into the API documentation and have not found a suitable solution or answer.
  • [X] I have searched the issues and have not found a suitable solution or answer.
  • [X] I have searched the Auth0 Community forums and have not found a suitable solution or answer.
  • [X] I agree to the terms within the Auth0 Code of Conduct.

Describe the problem you'd like to have solved

Desktop support especially with social providers would be awesome, there is currently no package that supports this.

Describe the ideal solution

Everything should work like now but there is probably more work to be done because windows does not support url redirects. Other packages start a http server and listen for callbacks but they are all specific to a product.

Alternatives and current workarounds

No response

Additional context

No response

Sesa1988 avatar Oct 16 '22 00:10 Sesa1988

Hi @Sesa1988, thanks for raising this.

Is this feature request for Windows support specifically?

Widcket avatar Oct 17 '22 22:10 Widcket

Hi @Sesa1988, thanks for raising this.

Is this feature request for Windows support specifically?

This was just my preference but web support would be nice as well.

Im looking for a auth package that can be used on all Flutter platforms that support azure ad b2c and similar services.

Sesa1988 avatar Oct 17 '22 22:10 Sesa1988

We already have https://github.com/auth0/auth0-flutter/issues/169 for tracking web support. As mentioned there:

Since Flutter for web supports interop with JS, you could use our SDK for SPAs: https://github.com/auth0/auth0-spa-js/.

Would that work for you?

Widcket avatar Oct 17 '22 23:10 Widcket

We already have https://github.com/auth0/auth0-flutter/issues/169 for tracking web support. As mentioned there:

Since Flutter for web supports interop with JS, you could use our SDK for SPAs: https://github.com/auth0/auth0-spa-js/.

Would that work for you?

Im not sure how well this plays with Flutter web but Im looking more for desktop support.

Sesa1988 avatar Oct 17 '22 23:10 Sesa1988

Thanks. We have no plans in the near term but I'll leave this issue open for future planning and reference.

Widcket avatar Oct 17 '22 23:10 Widcket

+1 to providing desktop support or making is clearer in the readme, tutorials, and quickstart that desktop is not supported.

Alternatively, it would be helpful to have a clearer error message. Trying to run auth0-flutter in a MacOS app results in the following error, which is misleading:

MissingPluginException(No implementation found for method webAuth#login on channel auth0.com/auth0_flutter/web_auth)

Thanks!

sir-dunxalot avatar Feb 15 '23 04:02 sir-dunxalot

@sir-dunxalot I think that's an error surfaced by the Flutter runtime rather than our plugin.

We're always happy to look at ways to make our support clearer. Currently the package on pub.dev is accurate in that it shows iOS and Android as supported platforms:

image

And we mention supported in the readme for this repo:

image

stevehobbsdev avatar Feb 24 '23 11:02 stevehobbsdev

+1 to providing desktop support. One of the main reasons to use flutter in the first place is to chase the dream of one codebase for all (relevant) platforms. Please add desktop (and web) support. Thanks!

keepersmith avatar Apr 09 '23 17:04 keepersmith

As I see it there are a few options:

Loopback: - potential MiTM risks

  1. Login triggers opening browser
  2. Perform normal login in browser
  3. Run server on loopback address
  4. Browser redirects to a loopback address (e.g. 127.0.0.1:1234)
  5. Close browser
  6. Loopback address broadly follows; https://github.com/auth0/auth0-flutter/blob/main/auth0_flutter/lib/src/web/auth0_flutter_plugin_real.dart
  7. Close loopback server and listen for login in initState.

Embedded Webview

  1. Open login in embedded webview
  2. Listen for relevant redirect and extract values

~~MacOS only~~ ~~1. Package redirect (e.g. https://auth0.com/docs/quickstart/native/ios-swift/interactive)~~

Keen for any feedback re recommended/agreeable direction, and I will begin to put a PR together.

steve-winter avatar Jul 10 '23 13:07 steve-winter

Any updates on this topic? We are currently using https://pub.dev/packages/flutter_appauth (as it was used in previous Auth0 blogs on how to integrate with Auth0 and flutter).

Since then macOS support has been added which we are using quite intensely. Do you have any idea on the timeline for macOS support for this lib? I think ideally we'd like to move over to this lib but no macOS support is blocking us currently.

JordyLangen avatar Aug 03 '23 14:08 JordyLangen

For me, it would be also really nice to have Auth0 support on desktop platforms. Any chance that this will be implemented in the near future? Especially macOS should be almost the same as iOS.

raphibolliger avatar Aug 04 '23 17:08 raphibolliger

+1

Anish-Chanda avatar Oct 05 '23 20:10 Anish-Chanda

@Widcket are there any plans currently to support this?

JordyLangen avatar Nov 13 '23 12:11 JordyLangen

Hi @JordyLangen, we are currently working on adding support for macOS, though I can't share a specific ETA yet.

Widcket avatar Nov 13 '23 13:11 Widcket

@Widcket thats good to hear! Do you have a time window? This year? Q1 next year?

JordyLangen avatar Nov 13 '23 15:11 JordyLangen

Though this is no ETA, a rough time window would be around end of year.

Widcket avatar Nov 13 '23 15:11 Widcket

Hey everyone, macOS support is out now on v1.5.0.

Widcket avatar Dec 15 '23 18:12 Widcket

Please provide support for windows as well

jaipal-sodhi avatar Feb 07 '24 06:02 jaipal-sodhi

@Widcket Any updates on Windows support? Is this going to be added in the near future?

Gaurav-CareMonitor avatar Apr 10 '24 03:04 Gaurav-CareMonitor