naiveproxy/services/network/public/interfaces/restricted_cookie_manager.mojom

33 lines
988 B
Plaintext
Raw Normal View History

2018-01-28 21:32:06 +03:00
// Copyright 2017 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
module network.mojom;
import "cookie_manager.mojom";
import "mojo/common/time.mojom";
import "url/mojo/url.mojom";
enum CookieMatchType {
EQUALS,
STARTS_WITH,
};
struct CookieManagerGetOptions {
string name;
CookieMatchType match_type;
};
interface RestrictedCookieManager {
// Returns the cookies visible by a Web page, filtered by |options|.
//
// |url| is the URL of the page making the request. |site_for_cookies| is
// described in RFC 6265bis. Values are populated by untrusted clients.
GetAllForUrl(
url.mojom.Url url, url.mojom.Url site_for_cookies,
CookieManagerGetOptions options) => (array<CanonicalCookie> cookies);
SetCanonicalCookie(CanonicalCookie cookie,
url.mojom.Url url,
url.mojom.Url site_for_cookies) => (bool success);
};