Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(478)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/cookies/CookiesFetcher.java

Issue 876973003: Implement the "first-party-only" cookie flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: FirstPartyOnly. Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/android/java/src/org/chromium/chrome/browser/cookies/CookiesFetcher.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/cookies/CookiesFetcher.java b/chrome/android/java/src/org/chromium/chrome/browser/cookies/CookiesFetcher.java
index ef545450c59c183af5130f7cc2b3c6c53b865624..bd6ceee6bef5c5e544416e59a0c45556bc81be1e 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/cookies/CookiesFetcher.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/cookies/CookiesFetcher.java
@@ -162,19 +162,11 @@ public class CookiesFetcher {
protected void onPostExecute(List<CanonicalCookie> cookies) {
// We can only access cookies and profiles on the UI thread.
for (CanonicalCookie cookie : cookies) {
- nativeRestoreCookies(mNativeCookiesFetcher,
- cookie.getUrl(),
- cookie.getName(),
- cookie.getValue(),
- cookie.getDomain(),
- cookie.getPath(),
- cookie.getCreationDate(),
- cookie.getExpirationDate(),
- cookie.getLastAccessDate(),
- cookie.isSecure(),
- cookie.isHttpOnly(),
- cookie.getPriority()
- );
+ nativeRestoreCookies(mNativeCookiesFetcher, cookie.getUrl(), cookie.getName(),
+ cookie.getValue(), cookie.getDomain(), cookie.getPath(),
+ cookie.getCreationDate(), cookie.getExpirationDate(),
+ cookie.getLastAccessDate(), cookie.isSecure(), cookie.isHttpOnly(),
+ cookie.isFirstPartyOnly(), cookie.getPriority());
}
}
}.executeOnExecutor(AsyncTask.SERIAL_EXECUTOR);
@@ -201,9 +193,9 @@ public class CookiesFetcher {
@CalledByNative
private CanonicalCookie createCookie(String url, String name, String value, String domain,
String path, long creation, long expiration, long lastAccess, boolean secure,
- boolean httpOnly, int priority) {
+ boolean httpOnly, boolean firstPartyOnly, int priority) {
return new CanonicalCookie(url, name, value, domain, path, creation, expiration, lastAccess,
- secure, httpOnly, priority);
+ secure, httpOnly, firstPartyOnly, priority);
}
@CalledByNative
@@ -292,8 +284,8 @@ public class CookiesFetcher {
private native long nativeInit();
private static native void nativeDestroy(long nativeCookiesFetcher);
private native void nativePersistCookies(long nativeCookiesFetcher);
- private native void nativeRestoreCookies(long nativeCookiesFetcher,
- String url, String name, String value, String domain, String path,
- long creation, long expiration, long lastAccess, boolean secure,
- boolean httpOnly, int priority);
+ private native void nativeRestoreCookies(long nativeCookiesFetcher, String url, String name,
+ String value, String domain, String path, long creation, long expiration,
+ long lastAccess, boolean secure, boolean httpOnly, boolean firstPartyOnly,
+ int priority);
}

Powered by Google App Engine
This is Rietveld 408576698