From 0d677bd8803c53bd74a6e92e9602f192587725a8 Mon Sep 17 00:00:00 2001 From: Nikolai R Kristiansen Date: Sat, 21 Mar 2015 20:21:38 +0100 Subject: [PATCH] Minor ldap sync url change --- inside/migration/config.example.php | 2 +- inside/migration/ldap_api_functions.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/inside/migration/config.example.php b/inside/migration/config.example.php index ea023c3..77fd0a6 100644 --- a/inside/migration/config.example.php +++ b/inside/migration/config.example.php @@ -2,4 +2,4 @@ define('ENC_KEY', "lol"); define('API_KEY', "lol"); -define('SYNC_HOST', "usersync.neuf.no"); +define('SYNC_NEW_USER_URL', "http://localhost:8000/usersync/"); diff --git a/inside/migration/ldap_api_functions.php b/inside/migration/ldap_api_functions.php index 92d0346..38612ab 100644 --- a/inside/migration/ldap_api_functions.php +++ b/inside/migration/ldap_api_functions.php @@ -2,7 +2,7 @@ require_once('config.php'); /* This file is an example on how you might push users from inside to ldap/radius. * * Basically, fill an array with the required attributes, get the API_KEY and the encryption key - * * and send it to the script addNewUser.php on SYNC_HOST. + * * and send it to the HTTP endpoint SYNC_NEW_USER_URL. * */ function enc_password($password, $key) { @@ -51,7 +51,7 @@ function ldap_add_user($username, $firstname, $lastname, $email, $password, $gro } /* Send the HTTP request. */ - $result = var_export(file_get_contents("http://".SYNC_HOST."/addNewUser.php?" . implode("&", $arr)), true); + $result = var_export(file_get_contents(SYNC_NEW_USER_URL."?" . implode("&", $arr)), true); return $result; } function _log($str) {