pub struct Cookie {
pub name: String,
pub value: String,
pub domain: String,
pub path: String,
pub expires: Option<u64>,
pub secure: bool,
pub http_only: bool,
pub host_only: bool,
pub same_site: SameSite,
pub partitioned: bool,
pub partition_key: Option<String>,
}Expand description
One parsed cookie. expires is a Unix epoch second; None means a
session cookie (lives only for this rsurl invocation, never persisted).
Fields§
§name: String§value: String§domain: StringEffective host the cookie applies to. Without the leading .
even when the Domain= attribute supplied one — the dot only
signals subdomain-match scope, which we track separately in
host_only rather than smuggling through the string.
path: String§expires: Option<u64>§secure: bool§http_only: bool§host_only: booltrue when the cookie was set without an explicit Domain= —
matches only the exact host. false means subdomain-match.
same_site: SameSiteThe SameSite attribute, parsed but not enforced (browser policy).
partitioned: booltrue when the Set-Cookie carried the Partitioned attribute (CHIPS,
RFC 6265bis). The actual partition key is assigned by the embedder from
the top-level site — see Cookie::partition_key.
partition_key: Option<String>The partition key (CHIPS) the embedder associates with this cookie, e.g.
the top-level site. None until set by the caller; rsurl does not derive
it (it has no notion of a top-level browsing context).