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

Website is vulnerable to HTML/JavaScript injection #6

Open
realityfabric opened this issue May 14, 2019 · 1 comment
Open

Website is vulnerable to HTML/JavaScript injection #6

realityfabric opened this issue May 14, 2019 · 1 comment
Assignees
Labels
vulnerability A security vulnerability, either for the server or for clients.

Comments

@realityfabric
Copy link
Owner

There is currently no input validation for user registration (or, honestly, anything that isn't automatically escaped by the pg_* functions). Users can register for an account with a username such as <SCRIPT SRC=http://xss.rocks/xss.js></SCRIPT> (one of the very first XSS injection attacks listed by OWASP.

@realityfabric realityfabric added the vulnerability A security vulnerability, either for the server or for clients. label May 14, 2019
@realityfabric realityfabric self-assigned this May 14, 2019
@realityfabric
Copy link
Owner Author

Created an "HTML safe" version of User::getUsername() (User::getUsernameHTMLSafe()).

This isn't enough, though. I need to go through and do input validation for all inputs and outputs.

I don't know if I want to prevent users from using special characters for usernames, but it is the standard so I probably will.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
vulnerability A security vulnerability, either for the server or for clients.
Projects
None yet
Development

No branches or pull requests

1 participant