pub struct Config {
pub dangerous_insecure_transport_protocol: bool,
pub dangerous_accept_invalid_certs: bool,
pub dangerous_accept_invalid_hostnames: bool,
pub endpoints: Vec<Url>,
pub pubkey: String,
pub require_signed_version: bool,
pub allow_downgrades: bool,
pub windows: Option<WindowsConfig>,
}Expand description
Updater configuration.
Fields§
§dangerous_insecure_transport_protocol: boolDangerously allow using insecure transport protocols for update endpoints.
dangerous_accept_invalid_certs: boolDangerously accept invalid TLS certificates for update requests.
dangerous_accept_invalid_hostnames: boolDangerously accept invalid hostnames for TLS certificates for update requests.
endpoints: Vec<Url>Updater endpoints.
pubkey: StringSignature public key.
require_signed_version: boolRequire the update signature to carry the version it was signed for, and reject the update when that version differs from the one announced by the update endpoint.
The endpoint response is fetched over TLS but is not itself signed, and the signature
only covers the downloaded artifact. Without this flag, anyone able to serve a crafted
response can pair an inflated version field with the url and signature of an
older release and force a downgrade to a genuine but outdated build, since that older
artifact carries a valid signature.
The signed version is read from the signature’s trusted comment, which is covered by the signature. Releases signed before the Tauri CLI started recording it carry no version, so enabling this rejects them. Re-sign and re-publish every release your users can still update from before turning this on.
This is checked independently of the version comparison: it constrains which artifact a given version number may resolve to, not whether that version is newer.
The default value of this flag is false.
allow_downgrades: boolAllow the updater to install a release whose version is not newer than the currently running one, changing the version check from “must be newer” to “must be different”.
Note that the updater only verifies the signature of the downloaded artifact, not the version advertised by the update endpoint, so enabling this removes the only guard against installing a previously released (and validly signed) version.
Ignored when the application sets a custom
Builder::default_version_comparator.
The default value of this flag is false.
windows: Option<WindowsConfig>The Windows configuration for the updater.