diff options
author | mkwst <mkwst@chromium.org> | 2016-03-15 03:07:52 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-03-15 10:09:31 +0000 |
commit | e1a295845cbc338a564dc04e6e3e69b29ba7862f (patch) | |
tree | 00535f752a8faa939a4d646ca0215423e93e8ee6 /android_webview/browser | |
parent | 752434c777d2e7b445e37629bf89ecc7c38c7c5c (diff) | |
download | chromium_src-e1a295845cbc338a564dc04e6e3e69b29ba7862f.zip chromium_src-e1a295845cbc338a564dc04e6e3e69b29ba7862f.tar.gz chromium_src-e1a295845cbc338a564dc04e6e3e69b29ba7862f.tar.bz2 |
SameSite: Implement 'Strict'/'Lax' attribute parsing.
https://tools.ietf.org/html/draft-west-first-party-cookies-06 introduced
the notion of "Strict" or "Lax" enforcement of the "SameSite" attribute.
This patch implements the infrastructure changes necessary to support
that distinction, but does not yet implement the behavioral change
(that is, after this patch, `SameSite` will be rejected, while
`SameSite=Strict` and `SameSite=Lax` will have the same behavior that
`SameSite` alone has today).
Most of this patch is occupied with the fairly mechanical process of
swapping out a new 'CookieSameSite' enum for the existing boolean in
various constructors and setters. The most interesting piece is the
change to the storage backend, which now stores 0, 1, or 2 in the
database to represent the possible values, rather than 0 or 1 to
represent the boolean.
BUG=459154
Review URL: https://codereview.chromium.org/1773133002
Cr-Commit-Position: refs/heads/master@{#381201}
Diffstat (limited to 'android_webview/browser')
-rw-r--r-- | android_webview/browser/net/aw_cookie_store_wrapper.cc | 4 | ||||
-rw-r--r-- | android_webview/browser/net/aw_cookie_store_wrapper.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/android_webview/browser/net/aw_cookie_store_wrapper.cc b/android_webview/browser/net/aw_cookie_store_wrapper.cc index 16f55dd..f726448 100644 --- a/android_webview/browser/net/aw_cookie_store_wrapper.cc +++ b/android_webview/browser/net/aw_cookie_store_wrapper.cc @@ -118,7 +118,7 @@ void SetCookieWithDetailsAsyncOnCookieThread( base::Time last_access_time, bool secure, bool http_only, - bool same_site, + net::CookieSameSite same_site, bool enforce_strict_secure, net::CookiePriority priority, const net::CookieStore::SetCookiesCallback& callback) { @@ -219,7 +219,7 @@ void AwCookieStoreWrapper::SetCookieWithDetailsAsync( base::Time last_access_time, bool secure, bool http_only, - bool same_site, + net::CookieSameSite same_site, bool enforce_strict_secure, net::CookiePriority priority, const SetCookiesCallback& callback) { diff --git a/android_webview/browser/net/aw_cookie_store_wrapper.h b/android_webview/browser/net/aw_cookie_store_wrapper.h index 2272c4d1..a5bbf1a 100644 --- a/android_webview/browser/net/aw_cookie_store_wrapper.h +++ b/android_webview/browser/net/aw_cookie_store_wrapper.h @@ -52,7 +52,7 @@ class AwCookieStoreWrapper : public net::CookieStore { base::Time last_access_time, bool secure, bool http_only, - bool same_site, + net::CookieSameSite same_site, bool enforce_strict_secure, net::CookiePriority priority, const SetCookiesCallback& callback) override; |