Skip to content
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

Fix cookie parsing when value is undefined #17298

Merged
merged 2 commits into from
Sep 22, 2023
Merged

Fix cookie parsing when value is undefined #17298

merged 2 commits into from
Sep 22, 2023

Conversation

markstory
Copy link
Member

Some server send malformed cookie name/value pairs that lack both the value and are missing an =.

Fixes #17296

Some server send malformed cookie name/value pairs that lack both the
value and are missing an `=`.

Fixes #17296
@markstory markstory added this to the 4.4.18 milestone Sep 21, 2023
$result = Cookie::createFromHeaderString($header);

$this->assertSame('', $result->getValue());
}
Copy link
Member

Choose a reason for hiding this comment

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

Can we label this as malformed so future devs know it wasn't some misinterpretation of the standard and remove the support?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't know if we'll be able to remove support as there will always be bad servers out in the wild.

@othercorey othercorey merged commit 34b4920 into 4.x Sep 22, 2023
11 of 13 checks passed
@othercorey othercorey deleted the issue-17296 branch September 22, 2023 07:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants