Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Security] Unserialize $parentData, if needed, to avoid errors#36862

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nicolas-grekas merged 1 commit intosymfony:4.4fromrfaivre:ticket_36813
May 18, 2020

Conversation

@rfaivre
Copy link
Contributor

Check that the $parentData is an array. If it's a string, the variable is unserialized.
Useful to not break the compatibility with the older versions.
Bug reproduced when upgrading from 3.4 to 4.4

QA
Branch?4.4
Bug fix?yes
New feature?no
Deprecations?no
TicketsFix#36813
LicenseMIT
Doc PRsymfony/symfony-docs#...

nacholibre reacted with thumbs up emoji
@nicolas-grekas
Copy link
Member

Should we need the same for these?

$ grep 'parent::__unserialize' * -rCore/Tests/Authentication/Token/AbstractTokenTest.php:        parent::__unserialize($parentState);Core/Tests/Exception/CustomUserMessageAuthenticationExceptionTest.php:        parent::__unserialize($parentData);Core/Authentication/Token/AbstractToken.php:     *         parent::__unserialize($parentData);Core/Authentication/Token/SwitchUserToken.php:        parent::__unserialize($parentData);Core/Authentication/Token/PreAuthenticatedToken.php:        parent::__unserialize($parentData);Core/Authentication/Token/RememberMeToken.php:        parent::__unserialize($parentData);Core/Authentication/Token/UsernamePasswordToken.php:        parent::__unserialize($parentData);Core/Authentication/Token/AnonymousToken.php:        parent::__unserialize($parentData);Core/Exception/UsernameNotFoundException.php:        parent::__unserialize($parentData);Core/Exception/AccountStatusException.php:        parent::__unserialize($parentData);Core/Exception/AuthenticationException.php:     *         parent::__unserialize($parentData);Core/Exception/CustomUserMessageAuthenticationException.php:        parent::__unserialize($parentData);Core/Exception/CustomUserMessageAccountStatusException.php:        parent::__unserialize($parentData);Guard/Token/PostAuthenticationGuardToken.php:        parent::__unserialize($parentData);Http/Authenticator/Token/PostAuthenticationToken.php:        parent::__unserialize($parentData);

@wouterj
Copy link
Member

wouterj commentedMay 18, 2020
edited
Loading

Should we need the same for these?

Except for the ones ending withTest, I think we should (and the last one, or do we want to have compatibility from 3.4 to 5.1?)

@rfaivre
Copy link
ContributorAuthor

I did the changes except forTest classes

wouterj reacted with rocket emoji

@nicolas-grekas
Copy link
Member

Thank you@rfaivre.

rfaivre reacted with thumbs up emoji

@nicolas-grekasnicolas-grekas merged commit638b200 intosymfony:4.4May 18, 2020
This was referencedMay 26, 2020
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Projects

None yet

Milestone

4.4

Development

Successfully merging this pull request may close these issues.

4 participants

@rfaivre@nicolas-grekas@wouterj@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp