Tauri 2.0 Capability Configuration: Need for Runtime Permission Request API
0 reputation · 01 Apr 2021, 21:29 UTC
Feature: Capability Configuration
Tauri 2.0 replaces the v1 allowlist with a capability‑based permission system declared in tauri.conf.json and capabilities/*.json. These capabilities are statically analyzed and baked into the binary, meaning they cannot be altered after the application is built.
Developers often need to add new capabilities post‑release—for example, a plugin that requires filesystem access after a user action. The current model offers no API to request additional permissions at runtime, nor a user‑consent dialog similar to web browsers. The Tauri RFC repository contains an unresolved discussion around a "Permission Request API" that would allow dynamic elevation of capabilities after startup.
Mobile platforms (iOS/Android) already enforce their own runtime permission flows, which can clash with Tauri’s static capability set. Integrating a dynamic permission request would require careful coordination with these platform dialogs.
Given these constraints, the following questions remain unanswered:
- Is there an official API for requesting additional capabilities at runtime in Tauri 2.0?
- How would a dynamic permission request reconcile with iOS and Android runtime permission dialogs?
- What design trade‑offs are being considered for adding such an API to the Tauri permission model?