pub enum DataStore {
Shared,
Isolated(String),
Proxied {
key: String,
port: u16,
ca: Vec<u8>,
spki_pins: String,
},
}Expand description
Which browser data store (cookies, localStorage, IndexedDB, cache) a new page uses.
Variants§
The default persistent store every non-isolated page shares.
Isolated(String)
A private in-memory store, keyed by the owning session’s id.
Pages opened with the same key share it; nothing outside that
key sees it. Engine::drop_store discards it, and it never
outlives the engine.
Proxied
An isolated store, keyed like Self::Isolated, whose network
traffic goes through the HTTP proxy at 127.0.0.1:<port>. Every
engine binds proxy settings to the store (macOS data store,
WebKitGTK network session, WebView2 environment), which is why a
proxied page cannot share the default store.
ca is the proxy’s CA certificate (DER). The proxy answers the
browser’s TLS with leaves it signs, so the engine trusts it for
this store’s pages, and only for them. spki_pins lists the
base64 SHA-256 of the leaf and CA public keys (comma-separated),
for engines that pin keys rather than anchors.