Skip to content
Snippets Groups Projects
Commit 2ea99e04 authored by Sonia Zorba's avatar Sonia Zorba
Browse files

Moved auth/oauth2 -> auth/social

parent 39e86f03
No related branches found
No related tags found
No related merge requests found
File moved
File moved
File moved
File moved
File moved
...@@ -59,16 +59,16 @@ $AUTHENTICATION_METHODS = array( ...@@ -59,16 +59,16 @@ $AUTHENTICATION_METHODS = array(
'Google' => array( 'Google' => array(
'id' => "XXXXXX", 'id' => "XXXXXX",
'secret' => "XXXXXX", 'secret' => "XXXXXX",
'callback' => $BASE_PATH . "/auth/oauth2/google_token.php"), 'callback' => $BASE_PATH . "/auth/social/google_token.php"),
'Facebook' => array( 'Facebook' => array(
'id' => "XXXXXX", 'id' => "XXXXXX",
'secret' => "XXXXXX", 'secret' => "XXXXXX",
'version' => "v3.0", 'version' => "v3.0",
'callback' => $BASE_PATH . "/auth/oauth2/facebook_token.php"), 'callback' => $BASE_PATH . "/auth/social/facebook_token.php"),
'LinkedIn' => array( 'LinkedIn' => array(
'id' => 'XXXXXX', 'id' => 'XXXXXX',
'secret' => 'XXXXXX', 'secret' => 'XXXXXX',
'callback' => $BASE_PATH . '/auth/oauth2/linkedin_token.php' 'callback' => $BASE_PATH . '/auth/social/linkedin_token.php'
), ),
'X.509' => array(), 'X.509' => array(),
'DirectIdP' => array( 'DirectIdP' => array(
......
...@@ -19,6 +19,8 @@ function checkUser() { ...@@ -19,6 +19,8 @@ function checkUser() {
} }
Flight::route('GET /admin', function() { Flight::route('GET /admin', function() {
checkUser();
global $VERSION; global $VERSION;
Flight::render('admin/index.php', array('title' => 'Admin panel', Flight::render('admin/index.php', array('title' => 'Admin panel',
'version' => $VERSION)); 'version' => $VERSION));
......
...@@ -54,15 +54,15 @@ function sendAuthRedirect($url) { ...@@ -54,15 +54,15 @@ function sendAuthRedirect($url) {
} }
Flight::route('/google', function() { Flight::route('/google', function() {
sendAuthRedirect('/auth/oauth2/google_token.php'); sendAuthRedirect('/auth/social/google_token.php');
}); });
Flight::route('/facebook', function() { Flight::route('/facebook', function() {
sendAuthRedirect('/auth/oauth2/facebook_login.php'); sendAuthRedirect('/auth/social/facebook_login.php');
}); });
Flight::route('/linkedIn', function() { Flight::route('/linkedIn', function() {
sendAuthRedirect('/auth/oauth2/linkedin_login.php'); sendAuthRedirect('/auth/social/linkedin_login.php');
}); });
Flight::route('/eduGAIN', function() { Flight::route('/eduGAIN', function() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment