Skip to content
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

Crashes on IE11 if sanitizing a space #372

Closed
sontek opened this issue Oct 18, 2019 · 6 comments
Closed

Crashes on IE11 if sanitizing a space #372

sontek opened this issue Oct 18, 2019 · 6 comments

Comments

@sontek
Copy link

sontek commented Oct 18, 2019

On IE11:

DOMPurify.sanitize(" ", {USE_PROFILES: {html: true}})
Unable to get property 'insertBefore' of undefined or null reference

Using latest version (2.0.6), you can verify it on:

https://cure53.de/purify

by opening the console and pasting the line of code above.

@cure53
Copy link
Owner

cure53 commented Oct 19, 2019

Oh, nice spot! We will release 2.0.7 soon and the bug will be fixed

@peterblazejewicz
Copy link

@sontek
This can be closed, as the 2.0.7 was released (and one of the product I work with uses IE11, so I've checked this thread).
Thanks!

@peterblazejewicz
Copy link

Hm,
so the '2.0.7' is not released via NPM yet?
The online version states '2.0.7' as the DOMPurify.version

@cure53
Copy link
Owner

cure53 commented Oct 21, 2019

Will be released very very soon :)

@cure53
Copy link
Owner

cure53 commented Oct 21, 2019

Pretty much on it right now

@cure53
Copy link
Owner

cure53 commented Oct 21, 2019

Alright, this fix should address the problem you described:

56b9e9c

Does it work as intended?

@cure53 cure53 closed this as completed Oct 21, 2019
peterblazejewicz added a commit to peterblazejewicz/DOMPurify that referenced this issue Oct 21, 2019
Add test case for sanitizing white space character returning empty
string.

See: cure53#372
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants