-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Replace html_janitor with sanitize-html #1275
Comments
It will break a backward capability of the API. So it can be done with the major release. |
What is the purpose of having the HTML sanitizer on frontend? You must sanitize the source on backend. Is it for extra safety? |
yes |
For what it's worth, I was playing around with this. sanitize-html increases the build size by about 200KiB while using something like isomorphic-dompurify is about the same size. I did a very simple implementation (ignores class and attribute) that didn't break the api by updating the clean method in sanitizer.ts
|
@neSpecc Hey, thanks for pointing me to this. Is there a plan to get this fixed any time soon? |
Hi, I just wondered if sanitize-html will not be a good candidate to replace html-janitor
I say this because:
This library has not been extensively tested. In particular versions prior to 2.0.3 are vulnerable to XSS attacks.
This vulnerability is fully described there: https://hackerone.com/reports/308155
https://www.npmjs.com/package/sanitize-html
worth it or not?
The text was updated successfully, but these errors were encountered: