[Security] Remove deprecated `RememberMeToken::getSecret()` and RememberMeToken's `$secret` property by ktherage · Pull Request #61011 · symfony/symfony · GitHub | Latest TMZ Celebrity News & Gossip | Watch TMZ Live
Skip to content

[Security] Remove deprecated RememberMeToken::getSecret() and RememberMeToken's $secret property #61011

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

Open
wants to merge 4 commits into
base: 8.0
Choose a base branch
from

Conversation

ktherage
Copy link
Contributor

@ktherage ktherage commented Jul 1, 2025

Q A
Branch? 8.0
Bug fix? no
New feature? yes
Deprecations? no
Issues --
License MIT

@ktherage ktherage requested a review from chalasr as a code owner July 1, 2025 09:44
@carsonbot carsonbot added this to the 8.0 milestone Jul 1, 2025
@ktherage ktherage changed the title [Security] Removal deprecated RememberMeToken::getSecret() and RememberMeToken's secret property [Security] Removal deprecated RememberMeToken::getSecret() and RememberMeToken's $secret property Jul 1, 2025
public function __serialize(): array
{
// $this->firewallName should be kept at index 1 for compatibility with payloads generated before Symfony 8
return [$this->secret, $this->firewallName, parent::__serialize()];
// Newly serialized data removes the secret deprecated since Symfony 7.2 and removed in Symfony 8.0
Copy link
Contributor

Choose a reason for hiding this comment

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

to be removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Maybe

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You mean the comment ? or the method ?

…berMeToken.php

Co-authored-by: Oskar Stark <oskarstark@googlemail.com>
@ktherage ktherage force-pushed the RememberMeToken-bc-layer-removal branch from 1f75ede to 002f9c9 Compare July 1, 2025 13:33
@ktherage ktherage force-pushed the RememberMeToken-bc-layer-removal branch from 002f9c9 to 63e71e7 Compare July 1, 2025 13:33
@alexandre-daubois alexandre-daubois changed the title [Security] Removal deprecated RememberMeToken::getSecret() and RememberMeToken's $secret property [Security] Remove deprecated RememberMeToken::getSecret() and RememberMeToken's $secret property Jul 2, 2025
Copy link
Member

@alexandre-daubois alexandre-daubois left a comment

Choose a reason for hiding this comment

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

After the discussion with Oskar is resolved 🙂

@welcoMattic welcoMattic added the BC Layer removal Used to track BC layer removals before a major release label Jul 4, 2025
}

public function __unserialize(array $data): void
{
[$this->secret, $this->firewallName, $parentData] = $data;
// BC Layer with payloads generated before Symfony 8.0
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// BC Layer with payloads generated before Symfony 8.0
// BC Layer with payloads generated before Symfony 8.0, to be removed in Symfony 9.0

Is it ok to keep such a BC Layer here? @OskarStark @stof

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BC Layer removal Used to track BC layer removals before a major release Security Status: Reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants

TMZ Celebrity News – Breaking Stories, Videos & Gossip

Looking for the latest TMZ celebrity news? You've come to the right place. From shocking Hollywood scandals to exclusive videos, TMZ delivers it all in real time.

Whether it’s a red carpet slip-up, a viral paparazzi moment, or a legal drama involving your favorite stars, TMZ news is always first to break the story. Stay in the loop with daily updates, insider tips, and jaw-dropping photos.

🎥 Watch TMZ Live

TMZ Live brings you daily celebrity news and interviews straight from the TMZ newsroom. Don’t miss a beat—watch now and see what’s trending in Hollywood.