Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

HTML render should be escaped #21

Open
mehaase opened this issue Dec 8, 2017 · 0 comments
Open

HTML render should be escaped #21

mehaase opened this issue Dec 8, 2017 · 0 comments

Comments

@mehaase
Copy link

mehaase commented Dec 8, 2017

The render_html() method does not sanitize outputs. If a database field contains <script>alert(1)</script>, this will lead to code execution in the user's browser.

Simple fix, change from this:

    		echo "\t<td>$cell</td>\n";

...to this:

    		$cell = htmlspecialchars($cell);
    		echo "\t<td>$cell</td>\n";
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant