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 issues with JSON output #10

Closed
JordanMilne opened this issue Jan 27, 2014 · 1 comment
Closed

XSS issues with JSON output #10

JordanMilne opened this issue Jan 27, 2014 · 1 comment

Comments

@JordanMilne
Copy link

All of the scripts in /sh/ return JSON, but the Content-Type header is being sent as text/html. This will cause XSS issues when attacker-controlled strings in the JSON are interpreted as HTML.

header('Content-Type: application/json; charset=UTF-8'); should be called before echoing anything to prevent this.

@tariqbuilds
Copy link
Owner

Thanks @JordanMilne . This has been addressed via a PR.

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