clean up username entered at login

darcs-hash:20080829225258-84dde-6fee5f0beea62f023c13436b8d7044241bc0d01a.gz
This commit is contained in:
Evan Prodromou 2008-08-29 18:52:58 -04:00
parent 9fb08ec45e
commit adeb19f1f7

View File

@ -39,7 +39,7 @@ class LoginAction extends Action {
function check_login() {
# XXX: form token in $_SESSION to prevent XSS
# XXX: login throttle
$nickname = $this->arg('nickname');
$nickname = common_canonical_nickname($this->trimmed('nickname'));
$password = $this->arg('password');
if (common_check_user($nickname, $password)) {
# success!