mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-09-26 03:19:05 +02:00
Fixed some errors in saml login system
This commit is contained in:
parent
27b3a8c2aa
commit
5fb6c1cbcd
@ -292,6 +292,11 @@ if (! isset ($config['id_user'])) {
|
|||||||
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;
|
||||||
|
if (!$nick_in_db) {
|
||||||
|
require_once('/opt/simplesamlphp/lib/_autoload.php');
|
||||||
|
$as = new SimpleSAML_Auth_Simple('example-userpass');
|
||||||
|
$as->logout();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
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.
|
||||||
@ -445,7 +450,7 @@ if (! isset ($config['id_user'])) {
|
|||||||
}
|
}
|
||||||
else { //login wrong
|
else { //login wrong
|
||||||
$blocked = false;
|
$blocked = false;
|
||||||
|
|
||||||
if ((!is_user_admin($nick) || $config['enable_pass_policy_admin']) && defined('PANDORA_ENTERPRISE')) {
|
if ((!is_user_admin($nick) || $config['enable_pass_policy_admin']) && defined('PANDORA_ENTERPRISE')) {
|
||||||
$blocked = login_check_blocked($nick);
|
$blocked = login_check_blocked($nick);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user