Skip to content

Fix #41: Response builder broke header value #42

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

Merged
merged 3 commits into from
Jun 27, 2016
Merged

Fix #41: Response builder broke header value #42

merged 3 commits into from
Jun 27, 2016

Conversation

mekras
Copy link
Contributor

@mekras mekras commented Jun 24, 2016

Q A
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Related tickets fixes #41

Checklist

  • Updated CHANGELOG.md to describe BC breaks / deprecations | new feature | bugfix

mekras added 2 commits June 24, 2016 16:06
As specified at [RFC7230](https://tools.ietf.org/html/rfc7230#section-3.2.4), headers charset should be limited to US-ASCII.
$name = trim(urldecode($parts[0]));
$value = trim(urldecode($parts[1]));
$name = trim($parts[0]);
$value = trim($parts[1]);
Copy link
Contributor

Choose a reason for hiding this comment

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

the urldecode was in there from the beginning. is something else doing that decoding in reality? is your test failing if you keep the urldecode here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

the urldecode was in there from the beginning. is something else doing that decoding in reality?

See comment for 60fe987

is your test failing if you keep the urldecode here?

Yes.

Copy link
Member

Choose a reason for hiding this comment

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

It seems to me the urldecode is not necessary, only ascii characters are allowed.

@sagikazarmark
Copy link
Member

Thank you for your work @mekras. Looks good to me. I am happy to merge it after a squash.

@sagikazarmark sagikazarmark modified the milestone: v1.2.1 Jun 24, 2016
@dbu dbu merged commit 15c0be7 into php-http:master Jun 27, 2016
@dbu
Copy link
Contributor

dbu commented Jun 27, 2016

thanks!

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.

Response builder broke header value
3 participants