From: VirtualTam Date: Thu, 4 Jan 2018 14:53:48 +0000 (+0100) Subject: Fix XSS vulnerability X-Git-Tag: v0.8.5~1 X-Git-Url: https://git.immae.eu/?p=github%2Fshaarli%2FShaarli.git;a=commitdiff_plain;h=aadec30ecd068a48ae3cbc920eff9f6ee47a24ed Fix XSS vulnerability Signed-off-by: VirtualTam --- diff --git a/index.php b/index.php index b4ccd1bd..d81712a6 100644 --- a/index.php +++ b/index.php @@ -459,7 +459,7 @@ if (isset($_POST['login'])) else { ban_loginFailed($conf); - $redir = '&username='. $_POST['login']; + $redir = '&username='. urlencode($_POST['login']); if (isset($_GET['post'])) { $redir .= '&post=' . urlencode($_GET['post']); foreach (array('description', 'source', 'title') as $param) {