Added CSRF checks to Tasks. Expect some error messages - and report them ;)

This commit is contained in:
Thomas Tanghus 2012-07-17 11:52:11 +02:00
parent 06ff6c6d7d
commit 8444fc5787
4 changed files with 4 additions and 0 deletions

View file

@ -3,6 +3,7 @@
// Init owncloud
OCP\JSON::checkLoggedIn();
OCP\JSON::checkAppEnabled('tasks');
OCP\JSON::callCheck();
$calendars = OC_Calendar_Calendar::allCalendars(OCP\User::getUser(), true);
$first_calendar = reset($calendars);

View file

@ -23,6 +23,7 @@
// Init owncloud
OCP\JSON::checkLoggedIn();
OCP\JSON::checkAppEnabled('tasks');
OCP\JSON::callCheck();
$id = $_POST['id'];
$task = OC_Calendar_App::getEventObject( $id );

View file

@ -3,6 +3,7 @@
// Init owncloud
OCP\JSON::checkLoggedIn();
OCP\JSON::checkAppEnabled('tasks');
OCP\JSON::callCheck();
$l10n = new OC_L10N('tasks');

View file

@ -9,6 +9,7 @@
// Init owncloud
OCP\JSON::checkLoggedIn();
OCP\JSON::checkAppEnabled('tasks');
OCP\JSON::callCheck();
$id = $_POST['id'];
$property = $_POST['type'];