This repository has been archived by the owner on Jun 4, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 74
feat: disable cookie access under restricted sandboxes #677
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When dash is embedded into an iframe with a sandbox attribute that only has allow-scripts, cookie access is disabled and dash-table fails to load. As such, we need to restrict our cookie usage by disabling functionality. This patch removes the disabled functionality in a graceful manner, allowing dash-table to load in very restricted iframes.
ef887dc
to
26d8641
Compare
} catch (e) { | ||
return false; | ||
} | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@josegonzalez As I'm nearing a release and would want to get this in -- and haven't looked at it soon enough, took the liberty of updating this code so that the CookieStorage.enbled
runs only once.
@@ -10,6 +10,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). | |||
|
|||
### Fixed | |||
- [#670](https://github.com/plotly/dash-table/pull/670) Fix a bug where `derived_filter_query_structure` was not getting updated properly | |||
- [#677](https://github.com/plotly/dash-table/pull/677) Fix a bug where the table fails to load when used inside an iframe with a sandbox attribute that only has allow-scripts |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@josegonzalez Added a changelog entry
Marc-Andre-Rivet
approved these changes
Jan 14, 2020
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💃
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When dash is embedded into an iframe with a sandbox attribute that only has allow-scripts, cookie access is disabled and dash-table fails to load. As such, we need to restrict our cookie usage by disabling functionality.
This patch removes the disabled functionality in a graceful manner, allowing dash-table to load in very restricted iframes.