mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
Added some changes to SAML login system.
This commit is contained in:
parent
158e4da8ed
commit
318ba4f049
@ -295,8 +295,7 @@ if (! isset ($config['id_user'])) {
|
|||||||
$nick_in_db = $_SESSION["prepared_login_da"]['id_user'];
|
$nick_in_db = $_SESSION["prepared_login_da"]['id_user'];
|
||||||
$expired_pass = false;
|
$expired_pass = false;
|
||||||
}
|
}
|
||||||
else if (($config['auth'] == 'saml') && $login_button_saml) {
|
else if (($config['auth'] == 'saml') && ($login_button_saml)) {
|
||||||
if (!is_user_admin($nick)) {
|
|
||||||
include_once(ENTERPRISE_DIR . "/include/auth/saml.php");
|
include_once(ENTERPRISE_DIR . "/include/auth/saml.php");
|
||||||
$saml_user_id = saml_process_user_login();
|
$saml_user_id = saml_process_user_login();
|
||||||
$nick_in_db = $saml_user_id;
|
$nick_in_db = $saml_user_id;
|
||||||
@ -306,11 +305,6 @@ if (! isset ($config['id_user'])) {
|
|||||||
$as->logout();
|
$as->logout();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
|
||||||
$config["auth_error"] = "Error - Cannot log in as admin with 'login with saml' button";
|
|
||||||
$nick_in_db = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else {
|
else {
|
||||||
// process_user_login is a virtual function which should be defined in each auth file.
|
// process_user_login is a virtual function which should be defined in each auth file.
|
||||||
// It accepts username and password. The rest should be internal to the auth file.
|
// It accepts username and password. The rest should be internal to the auth file.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user