Skip to content

Conversation

AlexeyLevin
Copy link

@AlexeyLevin AlexeyLevin commented Jan 19, 2019

#12 escape xml, html, etc. tags in message body

escape xml, html, etc. tags in message
<div>
<a href="#" class="toggle-msg"><i class="fa fa-chevron-circle-right">&nbsp;</i></a>
<pre class="message-body">${msg.message!''}</pre>
<pre class="message-body"><xmp>${msg.message!''}</xmp></pre>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From my understanding, the <xmp> tag is considered obsolete and deprecated. This would probably be better handled at the Freemarker level as it would also address any XSS vulnerabilities related to displaying message data.

https://freemarker.apache.org/docs/dgui_misc_autoescaping.html

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