Skip to content

Commit dbf4759

Browse files
committed
Deprecate null/empty string for secret argument
1 parent db2f206 commit dbf4759

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/Symfony/Component/Security/Http/RateLimiter/DefaultLoginRateLimiter.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,9 @@ final class DefaultLoginRateLimiter extends AbstractRequestRateLimiter
3232

3333
public function __construct(RateLimiterFactory $globalFactory, RateLimiterFactory $localFactory, #[\SensitiveParameter] string $secret = null)
3434
{
35+
if (!$secret) {
36+
trigger_deprecation('symfony/security-http', '6.4', 'Calling "%s()" with an empty secret is deprecated, pass a non-empty string instead.', __METHOD__);
37+
}
3538
$this->globalFactory = $globalFactory;
3639
$this->localFactory = $localFactory;
3740
$this->secret = $secret;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy