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

Do not attempt to escape cookie values. #1406

Merged
merged 1 commit into from Feb 17, 2016

Conversation

dvaeversted
Copy link
Contributor

Trust that the cookie value sent by the server is escaped accordingly,
and do not attempt to escape the cookie by adding quotes around the value.

This is a pull request for: #1405

I can see others have run into the same issue: http://tricksty.com/coding/remove-double-quotes-from-guzzle-cookies

*
* @return string
*/
public static function getCookieValue($value)
Copy link
Member

Choose a reason for hiding this comment

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

Instead of removing this public method, let's mark it as deprecated, remove the rest of the docblock other than the @deprecated annotation, and have it just return the value as-is. That way anyone calling this directly wont break.

@dvaeversted
Copy link
Contributor Author

Updated commit according to comments.

Trust that the cookie value sent by the server is escaped accordingly,
and do not attempt to escape the cookie by adding quotes around the value.
@mtdowling
Copy link
Member

thanks!

mtdowling added a commit that referenced this pull request Feb 17, 2016
Do not attempt to escape cookie values.
@mtdowling mtdowling merged commit 739b9c8 into guzzle:master Feb 17, 2016
@carlosV2
Copy link

I've spend two days debugging my app, goutte and guzzle till I found this as the root of my problem 😭

When is this going to be released? Thanks 😁

@avindra
Copy link
Contributor

avindra commented Mar 22, 2016

@carlosV2 : Released 20 hours ago

@carlosV2
Copy link

@avindra thanks and thanks for reporting it :)

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

4 participants