-
Notifications
You must be signed in to change notification settings - Fork 454
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
New tab using url_target="_blank" uses same session #1629
Comments
I found this which looks like our case: https://stackoverflow.com/questions/20879714/how-to-prevent-sessionstorage-being-inherited-when-using-target-blank-window I could be mistaken, but |
...and this could be a solution from a different angle - store session data in |
We've been storing sessionID in window.name because of #1629. However, `window.name` is not preserved in mobile Safari during OAuth session. It looks like Flutter has fixed that in launchUrl() (https://github.com/flutter/packages/blob/main/packages/url_launcher/url_launcher_web/lib/url_launcher_web.dart#L87) https://stackoverflow.com/a/73821739/1435891
* Fix "_FletSocketServer__receive_loop_task" error on Linux Fix #2781 * Replace deprecated `datetime.utcnow()` with `datetime.now(UTC)` Fix #2827 * Fix a call to `self.__executor.shutdown` for Python 3.8 Fix #2825 * Use `timezone.utc` instead of `datetime.UTC` * Add client IP and user agent to a session ID To make session ID hijacking harder * Generate crypto-strong strings * Flet version bumped to 0.21.2 * Ensure control exists in _process_remove_command * Store session ID in SessionStorage instead of window.name We've been storing sessionID in window.name because of #1629. However, `window.name` is not preserved in mobile Safari during OAuth session. It looks like Flutter has fixed that in launchUrl() (https://github.com/flutter/packages/blob/main/packages/url_launcher/url_launcher_web/lib/url_launcher_web.dart#L87) https://stackoverflow.com/a/73821739/1435891 * Changelog updated
* Added `page.debug` and `page.platform_brightness` props Close flet-dev#1649, close flet-dev#1630 * Store session ID in `window.name` Fix flet-dev#1629 * Do not assign random port on Windows with `--ios` flag Fix flet-dev#1620 * Update local_connection.py * Build Android QR
* Fix "_FletSocketServer__receive_loop_task" error on Linux Fix flet-dev#2781 * Replace deprecated `datetime.utcnow()` with `datetime.now(UTC)` Fix flet-dev#2827 * Fix a call to `self.__executor.shutdown` for Python 3.8 Fix flet-dev#2825 * Use `timezone.utc` instead of `datetime.UTC` * Add client IP and user agent to a session ID To make session ID hijacking harder * Generate crypto-strong strings * Flet version bumped to 0.21.2 * Ensure control exists in _process_remove_command * Store session ID in SessionStorage instead of window.name We've been storing sessionID in window.name because of flet-dev#1629. However, `window.name` is not preserved in mobile Safari during OAuth session. It looks like Flutter has fixed that in launchUrl() (https://github.com/flutter/packages/blob/main/packages/url_launcher/url_launcher_web/lib/url_launcher_web.dart#L87) https://stackoverflow.com/a/73821739/1435891 * Changelog updated
If I have a button that opens a new page on the same app, or the app itself, it uses the same session and any changes on the new tab reflect in the original tab.
Code example to reproduce the issue:
Start the app, click the new tab button. Any action to increase the value in the first tab are also shown in the second tab
Describe the results you received:
Any action to increase the value in the first tab are also shown in the second tab
Describe the results you expected:
The new tab should start a new session, not use the existing session. If I just open a new tab and type the address in the URL, a new session is started.
Additional information you deem important (e.g. issue happens only occasionally):
Flet version (
pip show flet
):Operating system:
macOS, tested in Safari and Firefox
Additional environment details:
The text was updated successfully, but these errors were encountered: