mirror of
https://github.com/curl/curl.git
synced 2026-08-25 21:03:34 +03:00
cookie: cap expire times to 400 days
The pending cookie RFC update (currently known as 6265bis draft-19) says Let cookie-age-limit be the maximum age of the cookie (which name of Max-Age and an attribute-value of expiry-time. SHOULD be 400 days or less. This change makes received cookies over the wire get capped to 400 days. It does not cap the expiry date of cookies loaded from file. It does this by rounding the expire time to a even minute. This, to allow the test suite to do the same and have a chance to get the same number for stable testing without requiring a debug build. The test script generates TWO numbers in the output file for each %days[] used in the input test file, and the function that subsequently compares and verifies output is fine with *either* of the two numbers. This is done so that if the test case is generated the second immediately before curl runs, that updated expiry number is also deemed okay. It still checks for an exact match of either number. Closes #15937
This commit is contained in:
parent
533dc84e6e
commit
386f570df6
10 changed files with 103 additions and 46 deletions
|
|
@ -58,9 +58,9 @@ Accept: */*
|
|||
# This file was generated by libcurl! Edit at your own risk.
|
||||
|
||||
127.0.0.1 FALSE / FALSE 0 name4 value
|
||||
127.0.0.1 FALSE / FALSE 5115959787 name3 value
|
||||
127.0.0.1 FALSE / FALSE %days[400] name3 value
|
||||
127.0.0.1 FALSE / FALSE 0 name2 value
|
||||
127.0.0.1 FALSE / FALSE 5115959787 name value
|
||||
127.0.0.1 FALSE / FALSE %days[400] name value
|
||||
</file>
|
||||
</verify>
|
||||
</testcase>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue