Skip to content

Commit 2a9d759

Browse files
Merge branch '6.4' into 7.0
* 6.4: Fix implicitly-required parameters minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench) Fix bad merge List CS fix in .git-blame-ignore-revs Fix implicitly-required parameters List CS fix in .git-blame-ignore-revs Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value [Messenger][AmazonSqs] Allow async-aws/sqs version 2
2 parents e8c726c + 38c083f commit 2a9d759

File tree

7 files changed

+7
-7
lines changed

7 files changed

+7
-7
lines changed

Adapter/ConnectionInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,5 +34,5 @@ public function isBound(): bool;
3434
* @throws ConnectionTimeoutException When the connection can't be created because of an LDAP_TIMEOUT error
3535
* @throws InvalidCredentialsException When the connection can't be created because of an LDAP_INVALID_CREDENTIALS error
3636
*/
37-
public function bind(string $dn = null, #[\SensitiveParameter] string $password = null): void;
37+
public function bind(?string $dn = null, #[\SensitiveParameter] ?string $password = null): void;
3838
}

Adapter/ExtLdap/Connection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ public function isBound(): bool
6262
/**
6363
* @param string $password WARNING: When the LDAP server allows unauthenticated binds, a blank $password will always be valid
6464
*/
65-
public function bind(string $dn = null, #[\SensitiveParameter] string $password = null): void
65+
public function bind(?string $dn = null, #[\SensitiveParameter] ?string $password = null): void
6666
{
6767
if (!$this->connection) {
6868
$this->connect();

Ldap.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ public function __construct(AdapterInterface $adapter)
2929
$this->adapter = $adapter;
3030
}
3131

32-
public function bind(string $dn = null, #[\SensitiveParameter] string $password = null): void
32+
public function bind(?string $dn = null, #[\SensitiveParameter] ?string $password = null): void
3333
{
3434
$this->adapter->getConnection()->bind($dn, $password);
3535
}

LdapInterface.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ interface LdapInterface
3030
*
3131
* @throws ConnectionException if dn / password could not be bound
3232
*/
33-
public function bind(string $dn = null, #[\SensitiveParameter] string $password = null): void;
33+
public function bind(?string $dn = null, #[\SensitiveParameter] ?string $password = null): void;
3434

3535
/**
3636
* Queries a ldap server for entries matching the given criteria.

Security/LdapAuthenticator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ public function onAuthenticationFailure(Request $request, AuthenticationExceptio
8080
return $this->authenticator->onAuthenticationFailure($request, $exception);
8181
}
8282

83-
public function start(Request $request, AuthenticationException $authException = null): Response
83+
public function start(Request $request, ?AuthenticationException $authException = null): Response
8484
{
8585
if (!$this->authenticator instanceof AuthenticationEntryPointInterface) {
8686
throw new NotAnEntryPointException(sprintf('Decorated authenticator "%s" does not implement interface "%s".', get_debug_type($this->authenticator), AuthenticationEntryPointInterface::class));

Security/LdapBadge.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ class LdapBadge implements BadgeInterface
3131
private string $searchPassword;
3232
private ?string $queryString;
3333

34-
public function __construct(string $ldapServiceId, string $dnString = '{user_identifier}', string $searchDn = '', string $searchPassword = '', string $queryString = null)
34+
public function __construct(string $ldapServiceId, string $dnString = '{user_identifier}', string $searchDn = '', string $searchPassword = '', ?string $queryString = null)
3535
{
3636
$this->ldapServiceId = $ldapServiceId;
3737
$this->dnString = $dnString;

Security/LdapUserProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class LdapUserProvider implements UserProviderInterface, PasswordUpgraderInterfa
4545
private ?string $passwordAttribute;
4646
private array $extraFields;
4747

48-
public function __construct(LdapInterface $ldap, string $baseDn, string $searchDn = null, #[\SensitiveParameter] string $searchPassword = null, array $defaultRoles = [], string $uidKey = null, string $filter = null, string $passwordAttribute = null, array $extraFields = [])
48+
public function __construct(LdapInterface $ldap, string $baseDn, ?string $searchDn = null, #[\SensitiveParameter] ?string $searchPassword = null, array $defaultRoles = [], ?string $uidKey = null, ?string $filter = null, ?string $passwordAttribute = null, array $extraFields = [])
4949
{
5050
$uidKey ??= 'sAMAccountName';
5151
$filter ??= '({uid_key}={user_identifier})';

0 commit comments

Comments
 (0)