small fixes (p1)

This commit is contained in:
RainLoop Team 2013-11-19 03:20:30 +04:00
parent 90496a0ff6
commit ea98954394
7 changed files with 30 additions and 13 deletions

View file

@ -112,9 +112,9 @@ class ServiceActions
try
{
if ($this->oHttp->IsPost() &&
$this->Config()->Get('security', 'csrf_protection', false)
&& $this->oHttp->GetPost('XToken', '') !== \RainLoop\Utils::GetCsrfToken())
if ($this->oHttp->IsPost() && !in_array($sAction, array('JsInfo', 'JsError')) &&
$this->Config()->Get('security', 'csrf_protection', false) &&
$this->oHttp->GetPost('XToken', '') !== \RainLoop\Utils::GetCsrfToken())
{
throw new \RainLoop\Exceptions\ClientException(\RainLoop\Notifications::InvalidToken);
}