https://github.com/symfony/symfony/blob/6.2/src/Symfony/Component/Ldap/LdapInterface.php#L45[`escape`] allows sanitizing these characters.
In the compliant solution example, the
`Ldap::escape` method is used with the `ESCAPE_FILTER` flag, which sanitizes potentially malicious characters in the search filter. The function can also be used with the
`ESCAPE_DN` flag, which sanitizes the distinguished name (DN).
Symfony also provides an
ad-hoc alternative for user lookup called
https://symfony.com/doc/current/security/ldap.html#security-ldap-user-provider[`LDAP User Provider`]. As opposed to the LDAP component, the LDAP User Provider