xss.js #76

Closed
wbw opened this Issue Apr 20, 2012 · 2 comments

Comments

Projects
None yet
2 participants
@wbw

wbw commented Apr 20, 2012

Would you consider rewriting the 'for(var i in compact_words)' (line97) to a normal for loop (perhaps all array iterators)?
Or add an ".hasOwnProperty" check?

The current code crashes under Node.js in combination with several other modules that extend the Array object since your iterator will try to do a ".split" on the extended properties which happen to be functions.

@chriso

This comment has been minimized.

Show comment Hide comment
@chriso

chriso Apr 22, 2012

Owner

Yeah not sure why that's there - fixing now. Out of interest, which modules are you using that extend Array? They should really be setting enumerable: false

Owner

chriso commented Apr 22, 2012

Yeah not sure why that's there - fixing now. Out of interest, which modules are you using that extend Array? They should really be setting enumerable: false

@chriso chriso closed this in c391e15 Apr 22, 2012

@wbw

This comment has been minimized.

Show comment Hide comment
@wbw

wbw Apr 22, 2012

Am using the node-mailchimp module

wbw commented Apr 22, 2012

Am using the node-mailchimp module

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment