mail icon indicating copy to clipboard operation
mail copied to clipboard

Provisioning and LDAP

Open ksteinb opened this issue 5 years ago • 3 comments

Hi,

automatic provisioning does not work with LDAP, as %USERID% fetches the UID, which is usually a UUID Value and completly senseless for Email, instead with LDAP we need the DisplayName (which is the real user login Name).

so please add the patch below to make also a %DISPLAYNAME% parameter available. `` *** Config.php.orig 2020-01-27 22:04:10.591445448 +0100 --- Config.php 2020-01-27 22:05:04.002460570 +0100


*** 112,118 **** }

    /**

! * Replace %USERID% and %EMAIL% to allow special configurations * * @param string $original * @param IUser $user --- 112,118 ---- }

    /**

! * Replace %USERID%, %DISPLAYNAME% and %EMAIL% to allow special configurations * * @param string $original * @param IUser $user


*** 122,127 **** --- 122,130 ---- if ($user->getUID() !== null) { $original = str_replace('%USERID%', $user->getUID(), $original); }

  •             if ($user->getDisplayName() !== null) {
    
  •                     $original = str_replace('%DISPLAYNAME%', $user->getDisplayName(), $original);
    
  •             }
              if ($user->getEMailAddress() !== null) {
                      $original = str_replace('%EMAIL%', $user->getEMailAddress(), $original);
              }
    

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

ksteinb avatar Jan 27 '20 21:01 ksteinb

Added comment : this is true in some cases, but not all, there should be also a way to get the login name used

ksteinb avatar Jan 27 '20 21:01 ksteinb

Please submit this as pull request.

ChristophWurst avatar Jan 28 '20 09:01 ChristophWurst

Sorry, I'm a little bit old stylish ... but I prove to be able to learn ;-)

I just added a pull request

Sincerly, Klaus

ksteinb avatar Jan 28 '20 10:01 ksteinb