You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficcontrol.apache.org by GitBox <gi...@apache.org> on 2019/11/15 20:52:31 UTC
[GitHub] [trafficcontrol] rawlinp opened a new pull request #4119: TO:
Consistently set Expires and Max-Age cookie headers
rawlinp opened a new pull request #4119: TO: Consistently set Expires and Max-Age cookie headers
URL: https://github.com/apache/trafficcontrol/pull/4119
## What does this PR (Pull Request) do?
Include the Expires and Max-Age cookie headers in the Set-Cookie
response header for:
- new cookie generation via all login/logout endpoints
- cookie "refreshing" via authenticated endpoints
Per https://tools.ietf.org/html/rfc6265 the Max-Age header should have
precedence when both headers are present, so including both cookie
headers should not be a problem.
Possibly related to #3397 since TR doesn't know what to do with auth cookies if they don't have an `Expires` or `Max-Age` header.
This is technically a regression from the Perl from what I can tell, because TO-Perl includes the `Expires` cookie header in login as well as non-login responses (TO-Go was only returning the `Expires` cookie header for login responses).
- [x] This PR fixes #REPLACE_ME OR is not related to any Issue
## Which Traffic Control components are affected by this PR?
- Traffic Ops
## What is the best way to verify this PR?
Run the TO API tests and the traffic_ops_golang unit tests.
Verify TP is still able to login/use the cookie through a few different pages in a few different browsers.
## If this is a bug fix, what versions of Traffic Control are affected?
- since 3.x
## The following criteria are ALL met by this PR
- [x] This PR includes tests OR I have explained why tests are unnecessary
- [x] Bugfix, no docs necessary
- [x] This PR includes an update to CHANGELOG.md OR such an update is not necessary
- [x] This PR includes any and all required license headers
- [x] This PR ensures that database migration sequence is correct OR this PR does not include a database migration
- [x] This PR **DOES NOT FIX A SERIOUS SECURITY VULNERABILITY** (see [the Apache Software Foundation's security guidelines](https://www.apache.org/security/) for details)
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services