Add CSRF checks

This commit is contained in:
Lukas Reschke 2012-07-20 15:45:17 +02:00
parent bd91ee4d22
commit c04aa8d6a9
3 changed files with 8 additions and 2 deletions

View File

@ -5,7 +5,9 @@
* later.
* See the COPYING-README file.
*/
OCP\JSON::callCheck();
$id = strip_tags($_POST['id']);
$idtype = strip_tags($_POST['idtype']);
$permission = (int) strip_tags($_POST['permission']);

View File

@ -6,6 +6,8 @@
* See the COPYING-README file.
*/
OCP\JSON::callCheck();
$id = strip_tags($_POST['id']);
$idtype = strip_tags($_POST['idtype']);
switch($idtype){

View File

@ -5,7 +5,9 @@
* later.
* See the COPYING-README file.
*/
OCP\JSON::callCheck();
$id = strip_tags($_POST['id']);
$idtype = strip_tags($_POST['idtype']);
switch($idtype){