hansott/psr7-cookies
Add and manage HTTP cookies on PSR-7 responses with a simple SetCookie helper. Create custom cookies, delete cookies, set long-lived cookies, or set cookies that expire at a specific time, then attach them to any Psr\Http\Message\ResponseInterface.
See https://github.com/hansott/psr7-cookies/issues/5#issuecomment-483602120
Adding a cookie to a PSR-7 message is the only thing that this library should do, the other functionality is removed.
How to upgrade?
RequestCookies -> $request->getCookieParams() gives you all request cookies in the format you're used to.Signer -> I'm not sure what I should recommend at this point, I'm not an expert at security. That's part of the reason why I'm dropping the sign cookie functionality.ResponseCookies -> Just use SetCookie->addToResponseThanks for understanding.
Hans
Although it's not an API change, users should be prepared to see exceptions for signed cookies.
Signed cookies are now signed using the name AND value (previously only the value). This makes sure that a signed cookie cannot be renamed without changing the signature.
RequestCookies & ResponseCookies now directly implement Iterator (before through CookieCollection interface), since only 2 downloads, no major/minor change. (c44b4ce)How can I help you explore Laravel packages today?