From 4bda68a9a25f2a99addd2e53315f3a1523b25848 Mon Sep 17 00:00:00 2001 From: stoccc Date: Sun, 19 Apr 2020 23:34:01 +0200 Subject: [PATCH 1/2] Update LdapBindAuthenticationProvider.php --- .../Provider/LdapBindAuthenticationProvider.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php b/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php index 00092c4313..e68649801b 100644 --- a/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php +++ b/src/Symfony/Component/Security/Core/Authentication/Provider/LdapBindAuthenticationProvider.php @@ -87,9 +87,8 @@ class LdapBindAuthenticationProvider extends UserAuthenticationProvider } try { - $username = $this->ldap->escape($username, '', LdapInterface::ESCAPE_DN); - if ($this->queryString) { + $username = $this->ldap->escape($username, '', LdapInterface::ESCAPE_FILTER); $query = str_replace('{username}', $username, $this->queryString); $result = $this->ldap->query($this->dnString, $query)->execute(); if (1 !== $result->count()) { @@ -98,6 +97,7 @@ class LdapBindAuthenticationProvider extends UserAuthenticationProvider $dn = $result[0]->getDn(); } else { + $username = $this->ldap->escape($username, '', LdapInterface::ESCAPE_DN); $dn = str_replace('{username}', $username, $this->dnString); } From 76072c6424840a137bd9cad609db3d7a79ce7ab0 Mon Sep 17 00:00:00 2001 From: Thomas Calvet Date: Mon, 20 Apr 2020 18:08:44 +0200 Subject: [PATCH 2/2] [FrameworkBundle] Fix session.attribute_bag service definition --- .../Bundle/FrameworkBundle/Resources/config/session.xml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Symfony/Bundle/FrameworkBundle/Resources/config/session.xml b/src/Symfony/Bundle/FrameworkBundle/Resources/config/session.xml index 9f3a5b78c1..9080af9379 100644 --- a/src/Symfony/Bundle/FrameworkBundle/Resources/config/session.xml +++ b/src/Symfony/Bundle/FrameworkBundle/Resources/config/session.xml @@ -41,7 +41,8 @@ - + + attributes