Struct tauri_utils::acl::capability::Capability
source · pub struct Capability {
pub identifier: String,
pub description: String,
pub context: CapabilityContext,
pub windows: Vec<String>,
pub permissions: Vec<PermissionEntry>,
pub platforms: Vec<Target>,
}Expand description
a grouping and boundary mechanism developers can use to separate windows or plugins functionality from each other at runtime.
If a window is not matching any capability then it has no access to the IPC layer at all.
This can be done to create trust groups and reduce impact of vulnerabilities in certain plugins or windows. Windows can be added to a capability by exact name or glob patterns like , admin- or main-window.
Fields§
§identifier: StringIdentifier of the capability.
description: StringDescription of the capability.
context: CapabilityContextExecution context of the capability.
At runtime, Tauri filters the IPC command together with the context to determine whether it is allowed or not and its scope.
windows: Vec<String>List of windows that uses this capability. Can be a glob pattern.
permissions: Vec<PermissionEntry>List of permissions attached to this capability. Must include the plugin name as prefix in the form of ${plugin-name}:${permission-name}.
platforms: Vec<Target>Target platforms this capability applies. By default all platforms applies.
Trait Implementations§
source§impl Clone for Capability
impl Clone for Capability
source§fn clone(&self) -> Capability
fn clone(&self) -> Capability
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more