From c988f76612a33509022ebd02a99c13074f17123a Mon Sep 17 00:00:00 2001 From: Matt Pass Date: Sun, 27 Jul 2014 12:49:39 +0100 Subject: [PATCH] auth action added We can now call an auth action along with the token and it will set our flag As a follow up, it continues what we were previously doing - showing manager pane or toggling file display Note: 2 x JS files can probably be removed for now. Was going to look into auth token validation here, but until I do, they're not needed. --- lib/github.php | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/lib/github.php b/lib/github.php index bec8396..7f31be2 100644 --- a/lib/github.php +++ b/lib/github.php @@ -13,6 +13,30 @@ if (!extension_loaded('openssl') || !in_array('https', $wrappers)) { // If we have an action to perform if (!$demoMode && isset($_SESSION['loggedIn']) && $_SESSION['loggedIn'] && isset($_GET['action']) && $sslAvail) { + // ==== + // AUTH + // ==== + if ($_GET['action']=="auth") { + $_SESSION['githubAuthToken'] = xssClean($_GET['token']); + echo ' + + + + + + + + '; + } // ===== // CLONE