mirror of
https://github.com/nextcloud/server.git
synced 2026-04-15 22:11:17 -04:00
fix(user_ldap): Fix crash in some code path when a DN is longer that 64
UserConfig throws in this case. Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
a17f4d4eb1
commit
f2a5a8d70e
1 changed files with 7 additions and 2 deletions
|
|
@ -166,8 +166,13 @@ class Manager {
|
|||
* @param string $id the Nextcloud username
|
||||
*/
|
||||
public function isDeletedUser(string $id): bool {
|
||||
return $this->userConfig->getValueBool(
|
||||
$id, 'user_ldap', 'isDeleted');
|
||||
try {
|
||||
return $this->userConfig->getValueBool($id, 'user_ldap', 'isDeleted');
|
||||
} catch (\InvalidArgumentException $e) {
|
||||
// Most likely the string is too long to be a valid user id
|
||||
$this->logger->debug('Invalid id given to isDeletedUser', ['exception' => $e]);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue