Skip to content

Commit

Permalink
Reland "[Cookie Expires/Max-Age Upper Limit] (3) Enable by default"
Browse files Browse the repository at this point in the history
This reverts commit c8b12486f3e497a3477614f3c2d9fc0d66f9d568.

Reason for revert: Fixing broken bots, underlying change is correct one

Original change's description:
> Revert "[Cookie Expires/Max-Age Upper Limit] (3) Enable by default"
>
> This reverts commit caff7911aeddc8d231dc335715d1dda404320f67.
>
> Reason for revert: Failing multiple bots
>
> Original change's description:
> > [Cookie Expires/Max-Age Upper Limit] (3) Enable by default
> >
> > This won't be committed until after shipping is approved.
> > For now, this is just for vetting.
> >
> > This CL is a part of a series:
> > (1) Add new UMA
> > (2) Implement limit behind flag
> > (3) Enable by default
> >
> > Spec:
> > httpwg/http-extensions#1732
> >
> > Bug: 1264458
> > Change-Id: Idc0469d260c4a5706a9c64feec9af5a0f490d311
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3561385
> > Reviewed-by: Christian Dullweber <[email protected]>
> > Reviewed-by: Clark DuVall <[email protected]>
> > Auto-Submit: Ari Chivukula <[email protected]>
> > Reviewed-by: David Roger <[email protected]>
> > Reviewed-by: Steven Bingler <[email protected]>
> > Commit-Queue: Ari Chivukula <[email protected]>
> > Reviewed-by: Kenichi Ishibashi <[email protected]>
> > Cr-Commit-Position: refs/heads/main@{#1003286}
>
> Bug: 1264458, 1325493
> Change-Id: Ia10ffe2f5b6b21a6de3f6bc3a3014510ac3a0e68
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3648321
> Commit-Queue: Lijin Shen <[email protected]>
> Owners-Override: Lijin Shen <[email protected]>
> Bot-Commit: Rubber Stamper <[email protected]>
> Cr-Commit-Position: refs/heads/main@{#1003366}

Bug: 1264458, 1325493
Change-Id: Id9a059fe1c9755420aacc5fb0fc428883259facf
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3645552
Reviewed-by: Kenichi Ishibashi <[email protected]>
Commit-Queue: Christian Dullweber <[email protected]>
Reviewed-by: Clark DuVall <[email protected]>
Reviewed-by: Christian Dullweber <[email protected]>
Auto-Submit: Ari Chivukula <[email protected]>
Reviewed-by: David Roger <[email protected]>
Reviewed-by: Steven Bingler <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1004201}
  • Loading branch information
arichiv authored and chromium-wpt-export-bot committed May 17, 2022
1 parent c1bda9b commit 4d6b7ec
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions cookie-store/cookieListItem_attributes.https.any.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
const kCurrentHostname = (new URL(self.location.href)).hostname;

const kOneDay = 24 * 60 * 60 * 1000;
const kFourHundredDays = 400 * kOneDay;
const kTenYears = 10 * 365 * kOneDay;
const kFourHundredDaysFromNow = Date.now() + kFourHundredDays;
const kTenYearsFromNow = Date.now() + kTenYears;

const kCookieListItemKeys =
Expand Down Expand Up @@ -68,7 +70,7 @@ promise_test(async testCase => {
assert_equals(cookie.value, 'cookie-value');
assert_equals(cookie.domain, null);
assert_equals(cookie.path, '/');
assert_approx_equals(cookie.expires, kTenYearsFromNow, kOneDay);
assert_approx_equals(cookie.expires, kFourHundredDaysFromNow, kOneDay);
assert_equals(cookie.secure, true);
assert_equals(cookie.sameSite, 'strict');
const itemKeys = Object.keys(cookie);
Expand All @@ -91,7 +93,7 @@ promise_test(async testCase => {
assert_equals(cookie.value, 'cookie-value');
assert_equals(cookie.domain, null);
assert_equals(cookie.path, '/');
assert_approx_equals(cookie.expires, kTenYearsFromNow, kOneDay);
assert_approx_equals(cookie.expires, kFourHundredDaysFromNow, kOneDay);
assert_equals(cookie.secure, true);
}, 'CookieListItem - cookieStore.set with expires set to a Date 10 ' +
'years in the future');
Expand Down

0 comments on commit 4d6b7ec

Please sign in to comment.