Check requesttoken

This commit is contained in:
Lukas Reschke 2013-02-12 11:35:16 +01:00
parent 2507e0da1d
commit a9c77ebaf8
3 changed files with 5 additions and 0 deletions

View File

@ -1,6 +1,7 @@
<?php <?php
OCP\JSON::checkAppEnabled('files_external'); OCP\JSON::checkAppEnabled('files_external');
OCP\JSON::callCheck();
if ( ! ($filename = $_FILES['rootcert_import']['name']) ) { if ( ! ($filename = $_FILES['rootcert_import']['name']) ) {
header("Location: settings/personal.php"); header("Location: settings/personal.php");

View File

@ -4,6 +4,8 @@ require_once 'Dropbox/autoload.php';
OCP\JSON::checkAppEnabled('files_external'); OCP\JSON::checkAppEnabled('files_external');
OCP\JSON::checkLoggedIn(); OCP\JSON::checkLoggedIn();
OCP\JSON::callCheck();
if (isset($_POST['app_key']) && isset($_POST['app_secret'])) { if (isset($_POST['app_key']) && isset($_POST['app_secret'])) {
$oauth = new Dropbox_OAuth_Curl($_POST['app_key'], $_POST['app_secret']); $oauth = new Dropbox_OAuth_Curl($_POST['app_key'], $_POST['app_secret']);
if (isset($_POST['step'])) { if (isset($_POST['step'])) {

View File

@ -4,6 +4,8 @@ require_once 'Google/common.inc.php';
OCP\JSON::checkAppEnabled('files_external'); OCP\JSON::checkAppEnabled('files_external');
OCP\JSON::checkLoggedIn(); OCP\JSON::checkLoggedIn();
OCP\JSON::callCheck();
$consumer = new OAuthConsumer('anonymous', 'anonymous'); $consumer = new OAuthConsumer('anonymous', 'anonymous');
$sigMethod = new OAuthSignatureMethod_HMAC_SHA1(); $sigMethod = new OAuthSignatureMethod_HMAC_SHA1();
if (isset($_POST['step'])) { if (isset($_POST['step'])) {