aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorAaron Dewes <aaron.dewes@protonmail.com>2023-04-28 10:04:26 +0000
committerAaron Dewes <aaron@runcitadel.space>2023-08-13 15:43:04 +0200
commit16908999edae23a31b3f748c31c6c3196b6ba1da (patch)
tree3cf60244b2da0e3ca71b39777375ac903a6d9d84 /apps
parent13d9494af32fb30c39f7ce64f781454681eb0379 (diff)
downloadnextcloud-server-16908999edae23a31b3f748c31c6c3196b6ba1da.tar.gz
nextcloud-server-16908999edae23a31b3f748c31c6c3196b6ba1da.zip
Simplify escapeFilterPart
Signed-off-by: Aaron Dewes <aaron.dewes@protonmail.com>
Diffstat (limited to 'apps')
-rw-r--r--apps/user_ldap/lib/Access.php4
1 files changed, 1 insertions, 3 deletions
diff --git a/apps/user_ldap/lib/Access.php b/apps/user_ldap/lib/Access.php
index 0b115c42764..8086b95271f 100644
--- a/apps/user_ldap/lib/Access.php
+++ b/apps/user_ldap/lib/Access.php
@@ -1421,9 +1421,7 @@ class Access extends LDAPUtility {
$asterisk = '*';
$input = mb_substr($input, 1, null, 'UTF-8');
}
- $search = ['*', '\\', '(', ')'];
- $replace = ['\\*', '\\\\', '\\(', '\\)'];
- return $asterisk . str_replace($search, $replace, $input);
+ return $asterisk . ldap_escape($input, '', LDAP_ESCAPE_FILTER);
}
/**