Skip to content

Replacing deprecated security context #4512

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

Closed
wants to merge 1 commit into from
Closed

Replacing deprecated security context #4512

wants to merge 1 commit into from

Conversation

Sgoettschkes
Copy link
Contributor

Q A
Doc fix? yes
New docs? no
Applies to 2.6+
Fixed tickets #4511

This PR turned out larger than wanted. I wasn't able to test all changes, but as stated in http://symfony.com/blog/new-in-symfony-2-6-security-component-improvements replacing should work without problems.

The `Symfony\Component\Security\Core\SecurityContextInterface` was deprecated
with symfony 2.6. All instances of this interface where replaced with
`Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface`
or
`Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface`
depending on the use case.
All instances of `SecurityContext` where replaced as well.
This was done based on the blog post
http://symfony.com/blog/new-in-symfony-2-6-security-component-improvements
@javiereguiluz
Copy link
Member

I think that there is a minor error in the PR number showed in the "Fixed tickets" row. Instead of 5411, your probably wanted to display 4511.

@Sgoettschkes
Copy link
Contributor Author

@javiereguiluz Yes, thanks for noticing. Updated!

@javiereguiluz
Copy link
Member

@Sgoettschkes you're going to hate me ... but I think there is again an error in the "Fixed tickets" PR number. Now it shows 4512 and you probably wanted to display 4511.

@Sgoettschkes
Copy link
Contributor Author

@javiereguiluz Not at all. It's my fault after all. Sorry for the confusion. Checked the link, it should be ok now.

@javiereguiluz
Copy link
Member

@Sgoettschkes everything is perfect now. Thanks!

@xabbuh
Copy link
Member

xabbuh commented Nov 22, 2014

@Sgoettschkes Thank you for your pull request. Though I think that this is already covered by #4188 which completely covers the split of the SecurityContext class.

@Sgoettschkes
Copy link
Contributor Author

@xabbuh Damned. Anyway, I'll review #4188 and compare it to my changes. Maybe it misses something. Afterwards this PR can be closed.

@xabbuh
Copy link
Member

xabbuh commented Nov 23, 2014

@Sgoettschkes It's indeed a good idea to check if nothing is missing in #4188 that is covered by your changes. 👍

@linaori
Copy link
Contributor

linaori commented Nov 24, 2014

@Sgoettschkes I think I've covered the most important things, I suggest you to fork my branch and see if there's still anything missing. I won't do any --force anymore, so you can safely use it.

{
$this->securityContext = $securityContext;
$this-$tokenStorage = $tokenStorage;
Copy link
Contributor

Choose a reason for hiding this comment

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

typo here

@xabbuh xabbuh closed this Nov 29, 2014
@xabbuh
Copy link
Member

xabbuh commented Nov 29, 2014

Closing here. @Sgoettschkes feel free to ping us if you notice anything that was not covered by #4188.

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.

6 participants