diff --git a/oauth/authorize.php b/oauth/authorize.php index 1b1defd..51813ac 100644 --- a/oauth/authorize.php +++ b/oauth/authorize.php @@ -111,7 +111,7 @@ if (empty($_POST)) { // print the authorization code if the user has authorized your client $is_authorized = ($_POST['authorized'] === 'Authorize'); -$server->handleAuthorizeRequest($request, $response, $is_authorized,$_SESSION['uid']); +$server->handleAuthorizeRequest($request, $response, $is_authorized,strtolower($_SESSION['uid'])); if ($is_authorized) { diff --git a/oauth/connexion.php b/oauth/connexion.php index 57edba1..6bd2480 100644 --- a/oauth/connexion.php +++ b/oauth/connexion.php @@ -33,7 +33,7 @@ else // Remove every html tag and useless space on username (to prevent XSS) $user=strip_tags(trim($_POST['user'])); - $user=$_POST['user']; + $user=strtolower($_POST['user']); $password=$_POST['password']; // Open a LDAP connection