laminas / laminas-diactoros

PSR HTTP Message implementations
https://docs.laminas.dev/laminas-diactoros/
BSD 3-Clause "New" or "Revised" License
487 stars 63 forks source link

Fix cookie parsing from headers in server request factory using globals. #193

Closed Xerkus closed 2 months ago

Xerkus commented 2 months ago

PHP used to encode space in cookie values as + in violation of RFCs until it was fixed in PHP 7.4. See https://bugs.php.net/bug.php?id=79174

We decode headers to read server request cookies when creating server request from globals. It was still converting + in the cookie value back to space.

This PR fixes our implementation to align it again with the supported PHP versions and RFCs.

Xerkus commented 2 months ago

@gsteel You want to release it as 3.3.1? We can do that but I was going to tag 3.4.0 anyway although phpunit 10 upgrade is a dev dependency and the whole thing can be easily reduced to a patch release.

gsteel commented 2 months ago

I think a 3.4.0 release is fine - I was questioning the change needing to go into 4.0 as a possible BC break, or not as the case may be

Xerkus commented 2 months ago

There is no chance for BC break here.