You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am not sure if this is a ng-showdown issue or Showdown issue but how to enable sanitization is missing from the docs. I had to look at multiple issues and the code itself to realise this.
Here is the option: $showdownProvider.setOption('sanitize', true)
The text was updated successfully, but these errors were encountered:
Enabling "Sanitize" is kind of a "false sense of security" measure since, by itself, it does not protect against XSS attacks.
In order for it to be really secure you should follow extra steps. So enabling it by default could give the user a false sense of security. Also, it can break some legit use cases (where the user doesn't want any input to be sanitized).
Although I'm not against turning it on by default, there are legit concerns that the user might think showdown is XSS safe when it is not.
by itself, it does not protect against XSS attacks?
Could you please expand on why is this te case ?
Reading the link you pasted, it seems to me that applying ngSanitize to the output of showdown should be enough to prevent XSS, but it looks like I may be missing something.
Hello,
I am not sure if this is a ng-showdown issue or Showdown issue but how to enable sanitization is missing from the docs. I had to look at multiple issues and the code itself to realise this.
Here is the option:
$showdownProvider.setOption('sanitize', true)
The text was updated successfully, but these errors were encountered: