ThexXTURBOXx / flutter_web_auth_2

Flutter plugin for authenticating a user with a web service
https://pub.dev/packages/flutter_web_auth_2
MIT License
53 stars 54 forks source link

[Bug]: Provide an example for constructing valid callback url for windows and linux systems #124

Closed ChManasa07 closed 2 months ago

ChManasa07 commented 2 months ago

Description

Currently, I am trying to implement a flutter desktop, android and iOS app for OAuth using custom redirect uri. The app is successfully navigating to Auth provider and authenticating there but never comes back to the flutter application.

In the Flutter desktop application, before leaving to auth provider, I am trying to create a local server with the port that my system is not listening to. like: http://localhost:62145/, but still the auth provider never comes back to the original flutter application.

Minimal Reproduction

Steps to reproduce the behaviour:

final result = await FlutterWebAuth2.authenticate(url: "", callbackUrlScheme: "http://localhost:62149/");

Exception or Error

Auth provider never returns.

Expected Behaviour

It should return a success or failure message back to the app.

Screenshots

No response

Additional context

No response

Device

Windows, Samsung Tablet.

OS

windows OS 10

Browser

Edge

Flutter version

3.19.4

flutter_web_auth_2 version

3.1.2

Checklist

ThexXTURBOXx commented 2 months ago

Please try out the 4.x pre releases

ChManasa07 commented 2 months ago

I have tried with 4.x as well, it stil remains same.

ThexXTURBOXx commented 2 months ago

For 4.x, make sure to follow the migration guide, also. Please also try out the example on your machine. If that works fine, the problem is in your setup and not within the package.

ThexXTURBOXx commented 2 months ago

I consider this solved, I think.