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
Fix tag helper regression #45027
Merged
Merged
Fix tag helper regression #45027
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
Vue.js, alpinejs, and potentially other JS libraries support tags starting with `@` symbols. This was broken by the recent security release in 649516c I've only added `@` to the list even though there are potentially other safe characters. We can add more if necessary (and if safe). Fixes: * #45014 * #44972
tenderlove
reviewed
May 5, 2022
tenderlove
approved these changes
May 5, 2022
This was referenced May 5, 2022
Hi, @eileencodes , @tenderlove , I am the author of the initial security patch. Sorry for the mess... I have just created a pull request to fix the issue completely, could you please review it? #45236 |
amartinfraguas
added a commit
to amartinfraguas/rails
that referenced
this pull request
Jun 16, 2022
A previous fix for protections for XSS in `ActionView::Helpers` and `ERB::Util` introduced a regression by not filtering HTML characters properly. This is a complete fix for that regression, related to rails#45027. We would need to support XHTML, HTML4 and HTML5. But since XHTML and HTML4 have had a note for future deprecation in the documentation for more than 5 years, simplify the filtering by removing support for XHTML and HTML4.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Vue.js, alpinejs, and potentially other JS libraries support tags
starting with
@
symbols. This was broken by the recent security release in649516c
I've only added
@
to the list even though there are potentially othersafe characters. We can add more if necessary (and if safe).
Fixes:
@
are escaped to_
#45014cc/ @tenderlove