Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
AD / LDAP Authentication
#4
Code:
if ($this->is_admin) {
  $authType = 'SQL'; // admin users always login locally
}
I would like users authenticated by AD/LDAP to be able to be admin too - This would only allow SQL users to be admin.

In the PDF, linked on the doc page at : http://corebos.com/documentation/lib/exe...n-v1.0.pdf

There is the following line in include/ldap/config.ldap.php :
Code:
$AUTHCFG['sql_account'] = array('admin', 'sqluser');

This applies to more than just LDAP - so maybe it could be in config.inc.php?

Code:
        $usr_name = $this->column_fields["user_name"];
        $result = $this->db->pquery('select id from vtiger_users where user_name=?', array($usr_name));
        if ($result && $this->db->num_rows($result)==1) {
                $row = $this->db->fetchByAssoc($result);
                $userid = $row['id'];
        } else {
                return false;
        }
        $authType = GlobalVariable::getVariable('User_AuthenticationType', 'SQL', 'Users', $userid);        
        
        $sql_auth_users = array('admin','sqluser'); // Move to config.inc.php?
        
        if (in_array($usr_name, $sql_auth_users)) {
            $this->log->debug("$usr_name exists in sql_auth_users, so using SQL Authentication");
            $authType = 'SQL';
        }
Reply


Messages In This Thread
AD / LDAP Authentication - by gaardam - 08-26-2019, 02:53 AM
RE: AD / LDAP Authentication - by gaardam - 08-28-2019, 01:22 AM
RE: AD / LDAP Authentication - by joebordes - 08-28-2019, 08:44 AM
RE: AD / LDAP Authentication - by gaardam - 08-28-2019, 10:58 PM
RE: AD / LDAP Authentication - by joebordes - 08-28-2019, 11:24 PM
RE: AD / LDAP Authentication - by gaardam - 08-28-2019, 11:34 PM
RE: AD / LDAP Authentication - by joebordes - 08-28-2019, 11:25 PM

Forum Jump:


Users browsing this thread: 1 Guest(s)