Skip to content
This repository was archived by the owner on Jan 30, 2020. It is now read-only.

Complete #28#87

Merged
weierophinney merged 4 commits intozendframework:masterfrom
weierophinney:hotfix/28
May 5, 2016
Merged

Complete #28#87
weierophinney merged 4 commits intozendframework:masterfrom
weierophinney:hotfix/28

Conversation

@weierophinney
Copy link
Member

@weierophinney weierophinney commented May 5, 2016

This patch incorporates the patches from #28, with the following additions:

  • Incorporates feedback regarding ASCII range.
  • Removes an unnecessary test.
  • Adds a test case in the validateValues() provider to ensure that \r\n\t is recognized as a valid header wrap.
  • Updates the code so that this last test case actually passes.

In addition, I was unable to run php-cs-fixer when testing after running composer update --prefer-lowest. As such, this patch switches to phpcs, and corrects all CS issues flagged.

Fix #28
Close #65

MellieVT and others added 4 commits October 8, 2015 09:13
Fix HeaderValue throwing an exception on legal characters
- Changes the ASCII out-of-range checks to use `> 127` instead of `>
  126`, as 127 is the last ASCII character.
- Removed the `testCannotBeConstructed()` test case, as irrelevant.
- Added a data provider to test that wrapping header lines using
  `\r\n\t` is valid. It failed, and, as such, I updated the `isValid()`
  code to check for both ASCII 32 (SP) and 9 (TAB) when checking for
  line wrapping.
Had issues running CS sniffs under `--prefer-lowest`, so switched to phpcs.
Which helped uncover a ton of CS issues, including underscore-prefixed
properties and methods (most were updated, though the methods defined in the
abstract protocol class were left due to the fact that they are an extension
point).
@weierophinney weierophinney added this to the 2.7.1 milestone May 5, 2016
@weierophinney weierophinney self-assigned this May 5, 2016
weierophinney added a commit that referenced this pull request May 5, 2016
weierophinney added a commit that referenced this pull request May 5, 2016
Forward port #28
Forward port #87
@weierophinney weierophinney merged commit baf0f72 into zendframework:master May 5, 2016
weierophinney added a commit that referenced this pull request May 5, 2016
@Maks3w
Copy link
Member

Maks3w commented May 5, 2016

@weierophinney Note this should be backported to 2.4 series

@weierophinney
Copy link
Member Author

@Maks3w why? I don't see any discussion around that on the original patch...

@Maks3w
Copy link
Member

Maks3w commented May 6, 2016

Because this bug was introduced by the zend mail headers security patch which it was applied to 2.4 too

@glensc
Copy link
Contributor

glensc commented Jan 18, 2017

hard to see what the changes here are, because phpcs diff in same MR. i attempted to cherry-pick this to 2.4 branch, but seems the changes are already there

40fbcbe
e1c049e

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants