-
Notifications
You must be signed in to change notification settings - Fork 27
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
svg sanitizing #5120
base: master
Are you sure you want to change the base?
svg sanitizing #5120
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #5120 +/- ##
=======================================
Coverage 96.73% 96.73%
=======================================
Files 775 776 +1
Lines 26662 26681 +19
Branches 3468 3469 +1
=======================================
+ Hits 25792 25811 +19
Misses 608 608
Partials 262 262 ☔ View full report in Codecov by Sentry. |
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.
Nice, just a few things keep in mind :)
Added svg sanitation to the SVGOrImageField class, using the bleach library. The sanitation eliminates script tags, event handlers and non-essential tags and attributes (like Animation stuff, data-*, href) The allowed tags and attributes are derived from the MDN documentation about SVG content.
e923789
to
16355a9
Compare
Closes open-formulieren/security-issues#35
Changes
Added svg sanitizing to
SVGOrImageField
Checklist
Check off the items that are completed or not relevant.
Impact on features
Release management
I have updated the translations assets (you do NOT need to provide translations)
./bin/makemessages_js.sh
./bin/compilemessages_js.sh
Dockerfile/scripts
./bin
folderCommit hygiene