Merge branch 'maint'

This commit is contained in:
Lukas Fleischer 2013-01-30 09:25:42 +01:00
commit 8b791dee91
4 changed files with 30 additions and 15 deletions

View file

@ -94,7 +94,7 @@ function check_sid($dbh=NULL) {
* @return bool True if the CSRF token is the same as the cookie SID, otherwise false
*/
function check_token() {
if (isset($_POST['token'])) {
if (isset($_POST['token']) && isset($_COOKIE['AURSID'])) {
return ($_POST['token'] == $_COOKIE['AURSID']);
} else {
return false;