@@ -486,6 +486,8 @@ Configuration example for form login and query_string
486
486
service : Symfony\Component\Ldap\Ldap
487
487
dn_string : ' dc=example,dc=com'
488
488
query_string : ' (&(uid={username})(memberOf=cn=users,ou=Services,dc=example,dc=com))'
489
+ search_dn : ' ...'
490
+ search_password : ' the-raw-password'
489
491
490
492
.. code-block :: xml
491
493
@@ -502,7 +504,9 @@ Configuration example for form login and query_string
502
504
<form-login-ldap
503
505
service =" Symfony\Component\Ldap\Ldap"
504
506
dn-string =" dc=example,dc=com"
505
- query-string =" (& (uid={username})(memberOf=cn=users,ou=Services,dc=example,dc=com))" />
507
+ query-string =" (& (uid={username})(memberOf=cn=users,ou=Services,dc=example,dc=com))"
508
+ search-dn =" ..."
509
+ search-password =" the-raw-password" />
506
510
</firewall >
507
511
</config >
508
512
</srv : container >
@@ -519,12 +523,19 @@ Configuration example for form login and query_string
519
523
'service' => Ldap::class,
520
524
'dn_string' => 'dc=example,dc=com',
521
525
'query_string' => '(& (uid={username})(memberOf=cn=users,ou=Services,dc=example,dc=com))',
526
+ 'search_dn' => '...',
527
+ 'search_password' => 'the-raw-password',
522
528
// ...
523
529
],
524
530
],
525
531
]
526
532
]);
527
533
534
+ .. deprecated :: 4.4
535
+
536
+ Using the ``query_string `` config option without defining ``search_dn `` and
537
+ ``search_password `` is deprecated since Symfony 4.4.
538
+
528
539
.. _`LDAP PHP extension` : http://www.php.net/manual/en/intro.ldap.php
529
540
.. _`RFC4515` : http://www.faqs.org/rfcs/rfc4515.html
530
541
.. _`LDAP injection` : http://projects.webappsec.org/w/page/13246947/LDAP%20Injection
0 commit comments