-
Notifications
You must be signed in to change notification settings - Fork 5
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
Regular expressions still aren’t the right way #4
Comments
Interesting! |
Closed by b35dea0 as XSS-related filtering is delegated to chriso/node-validator.
Sure does. If there's something missing, a proper bug report or pull request is welcome. |
sanitize.stripComments("<!-- This HTML is <em>commented out</em>. -->") |
Congratulations on bringing in another sanitizer, but as this was directed RSS feeds, it’ll be unfortunate if someone ever wants to write about cookies. On the other hand, security that defeats itself is my favourite kind. There’s still a vulnerability, but I think I have to go report that to node-validator. (I could also not, because regular expressions aren’t the right way to go about this.) |
(For reference, it’s validatorjs/validator.js#223.) |
node-validator has removed its “XSS sanitizer” because it didn’t work; you should try going with Caja, which almost certainly will. It’ll be faster to boot. |
I’d appreciate it if you reopened the old issue — it’s more likely that someone notices that way — but here’s another “stripping creates exploit” problem in
stripUnsafeAttrs
instead ofstripUnsafeTags
:The text was updated successfully, but these errors were encountered: