Skip to content

[Security] Deprecate "always authenticate" and "exception on no token" #41965

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 8, 2021

Conversation

wouterj
Copy link
Member

@wouterj wouterj commented Jul 3, 2021

Q A
Branch? 5.4
Bug fix? no
New feature? no
Deprecations? yes
Tickets Ref #41613
License MIT
Doc PR n/a

@wouterj wouterj requested a review from chalasr as a code owner July 3, 2021 22:10
@wouterj wouterj force-pushed the pull-41613/signature-changes branch 3 times, most recently from 8e434bf to d4e33ca Compare July 3, 2021 23:45
@wouterj wouterj force-pushed the pull-41613/signature-changes branch from d4e33ca to 4bba287 Compare July 4, 2021 09:08
Copy link
Member

@chalasr chalasr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 with minor comment on the wording

@@ -34,6 +34,13 @@ class AuthorizationChecker implements AuthorizationCheckerInterface

public function __construct(TokenStorageInterface $tokenStorage, AuthenticationManagerInterface $authenticationManager, AccessDecisionManagerInterface $accessDecisionManager, bool $alwaysAuthenticate = false, bool $exceptionOnNoToken = true)
{
if (false !== $alwaysAuthenticate) {
trigger_deprecation('symfony/security-core', '5.4', 'Not setting the 4th argument of "%s" to "false" is deprecated.', __METHOD__);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

(minor) we might prefer talking about arguments names over positions in deprecation messages, see e.g. 8e3058d

@fabpot
Copy link
Member

fabpot commented Jul 8, 2021

Thank you @wouterj.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants