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
56 stars 55 forks source link

Authentication with logout URL #130

Closed tarek903 closed 2 months ago

tarek903 commented 2 months ago

Is your feature request related to a problem? Please describe.

first of all, thank you for such a nice pub, and I appreciate your effort, now to the matter in hand, I've seen you comment on multiple posts that there is no logic for logout, and people should use authenticate with logout URL, and I've done so but the authentication web windows doesn't close, since the logout URL is a redirection to the homepage (frontend business). and if I click on cancel it catches the exception of "user canceling login". also I tried adding the "preferEphemeral" and it works fine, but I try to login via facebook or google it can't see my google or facebook accounts.

Describe the solution you'd like

either add some kind of mechanism to close the webview, or maybe a way to clear the cache or cookies so the user can each time have a new login session.

any solution or workarounds will be highly appropriate.

ThexXTURBOXx commented 2 months ago

Indeed, these are the limitations of this package and to be honest, I am not planning on adding more support for logout functionalities. The easiest way is to have some API endpoint which invalidates the respective current session/cookie/whatever.

tarek903 commented 2 months ago

thank you for your answer, sadly the sessions are saved on people devices and no way to manage them.

closing the thread for now, have a nice day.