summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-04-24 13:27:29 +0200
committerAleksander Machniak <alec@alec.pl>2013-04-24 13:28:24 +0200
commit4571305398832109bae57be87961f68a38bf7d05 (patch)
treeb394f0c16df8c186b669518df1bf828b34007af6
parent32229952edfe2fad569996d8b437c6a70c4fd1bf (diff)
Fix error when using check_referer=true
-rw-r--r--CHANGELOG1
-rw-r--r--index.php4
-rw-r--r--program/include/bc.php2
3 files changed, 4 insertions, 3 deletions
diff --git a/CHANGELOG b/CHANGELOG
index cab99352a..2b0423110 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,6 +1,7 @@
CHANGELOG Roundcube Webmail
===========================
+- Fix error when using check_referer=true
- Fix incorrect handling of some specific links (#1489060)
- Fix incorrect handling of leading spaces in text wrapping
- Fix unintentional messages list jumps on click in Internet Explorer (#1489056)
diff --git a/index.php b/index.php
index f34b07cf3..ae6a91ff9 100644
--- a/index.php
+++ b/index.php
@@ -161,7 +161,7 @@ if ($RCMAIL->task == 'login' && $RCMAIL->action == 'login') {
}
// end session (after optional referer check)
-else if ($RCMAIL->task == 'logout' && isset($_SESSION['user_id']) && (!$RCMAIL->config->get('referer_check') || rcmail::check_referer())) {
+else if ($RCMAIL->task == 'logout' && isset($_SESSION['user_id']) && (!$RCMAIL->config->get('referer_check') || rcube_utils::check_referer())) {
$userdata = array(
'user' => $_SESSION['username'],
'host' => $_SESSION['storage_host'],
@@ -236,7 +236,7 @@ else {
}
// check referer if configured
- if ($RCMAIL->config->get('referer_check') && !rcmail::check_referer()) {
+ if ($RCMAIL->config->get('referer_check') && !rcube_utils::check_referer()) {
raise_error(array(
'code' => 403, 'type' => 'php',
'message' => "Referer check failed"), true, true);
diff --git a/program/include/bc.php b/program/include/bc.php
index 3d9d46289..af2e51210 100644
--- a/program/include/bc.php
+++ b/program/include/bc.php
@@ -287,7 +287,7 @@ function rcmail_remote_ip()
function rcube_check_referer()
{
- return rcmail::check_referer();
+ return rcube_utils::check_referer();
}
function rcube_timer()