Skip to content

Conversation

stokito
Copy link

@stokito stokito commented Apr 20, 2018

Each cell in CSV can contain special characters like <, > which can be considered by browser as a begging of HTML tag. This can broke layout and even can be used by a hacker for https://www.owasp.org/index.php/Cross-site_Scripting_(XSS)

  1. Improved performance by reusing jQuery object instead of getting it from DOM by selector each time.
  2. Use jQuery methods instead of manual HTML concatenation and manipulation.
  3. Escape html while rendering cell content

@stokito
Copy link
Author

stokito commented May 11, 2018

Please review my PR: it's simple but contains a security fix

@stokito
Copy link
Author

stokito commented Jul 14, 2018

Hi @derekeder

Could you please take a look on this patch? Thank you

@derekeder derekeder merged commit 255a6e6 into derekeder:master Jul 14, 2018
@derekeder
Copy link
Owner

@stokito thanks for this & sorry for my delay in reviewing. PR approved & merged

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

Successfully merging this pull request may close these issues.

2 participants