CVE-2023-46115
Updater Private Keys Possibly Leaked via Vite Environment Variables in tauri-cli
Severity Score
Exploit Likelihood
Affected Versions
Public Exploits
0Exploited in Wild
-Decision
Descriptions
Tauri is a framework for building binaries for all major desktop platforms. This advisory is not describing a vulnerability in the Tauri code base itself but a commonly used misconfiguration which could lead to leaking of the private key and updater key password into bundled Tauri applications using the Vite frontend in a specific configuration. The Tauri documentation used an insecure example configuration in the `Vite guide` to showcase how to use Tauri together with Vite. Copying the following snippet `envPrefix: ['VITE_', 'TAURI_'],` from this guide into the `vite.config.ts` of a Tauri project leads to bundling the `TAURI_PRIVATE_KEY` and `TAURI_KEY_PASSWORD` into the Vite frontend code and therefore leaking this value to the released Tauri application. Using the `envPrefix: ['VITE_'],` or any other framework than Vite means you are not impacted by this advisory. Users are advised to rotate their updater private key if they are affected by this (requires Tauri CLI >=1.5.5). After updating the envPrefix configuration, generate a new private key with `tauri signer generate`, saving the new private key and updating the updater's `pubkey` value on `tauri.conf.json` with the new public key. To update your existing application, the next application build must be signed with the older private key in order to be accepted by the existing application.
Tauri es un framework para crear archivos binarios para las principales plataformas de escritorio. Este aviso no describe una vulnerabilidad en el código base de Tauri en sí, sino una configuración incorrecta de uso común que podría provocar la filtración de la clave privada y la contraseña de la clave de actualización en aplicaciones Tauri empaquetadas que utilizan la interfaz Vite en una configuración específica. La documentación de Tauri utilizó una configuración de ejemplo insegura en "Vite guide" para mostrar cómo usar Tauri junto con Vite. Copiar el siguiente fragmento `envPrefix: ['VITE_', 'TAURI_'],` de esta guía en `vite.config.ts` de un proyecto Tauri lleva a agrupar `TAURI_PRIVATE_KEY` y `TAURI_KEY_PASSWORD` en el código de interfaz de Vite y por lo tanto filtrar este valor a la aplicación Tauri lanzada. El uso de `envPrefix: ['VITE_'],` o cualquier otro marco que no sea Vite significa que este aviso no lo afecta. Se recomienda a los usuarios que roten su clave privada de actualización si se ven afectados por esto (requiere Tauri CLI >=1.5.5). Después de actualizar la configuración de envPrefix, genere una nueva clave privada con `tauri signer generate`, guarde la nueva clave privada y actualice el valor `pubkey` del actualizador en `tauri.conf.json` con la nueva clave pública. Para actualizar su aplicación existente, la siguiente compilación de la aplicación debe firmarse con la clave privada anterior para que la aplicación existente la acepte.
CVSS Scores
SSVC
- Decision:Track*
Timeline
- 2023-10-16 CVE Reserved
- 2023-10-19 CVE Published
- 2023-10-20 EPSS Updated
- 2024-09-12 CVE Updated
- ---------- Exploited in Wild
- ---------- KEV Due Date
- ---------- First Exploit
CWE
- CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
- CWE-522: Insufficiently Protected Credentials
CAPEC
References (2)
URL | Tag | Source |
---|---|---|
https://tauri.app/v1/guides/getting-started/setup/vite | Product |
URL | Date | SRC |
---|
URL | Date | SRC |
---|
URL | Date | SRC |
---|---|---|
https://github.com/tauri-apps/tauri/security/advisories/GHSA-2rcp-jvr4-r259 | 2023-10-26 |
Affected Vendors, Products, and Versions
Vendor | Product | Version | Other | Status | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Vendor | Product | Version | Other | Status | <-- --> | Vendor | Product | Version | Other | Status |
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | < 2.0.0 Search vendor "Tauri" for product "Tauri" and version " < 2.0.0" | - |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha0 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha10 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha11 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha12 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha13 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha14 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha15 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha2 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha3 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha4 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha5 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha6 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha7 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha8 |
Affected
| ||||||
Tauri Search vendor "Tauri" | Tauri Search vendor "Tauri" for product "Tauri" | 2.0.0 Search vendor "Tauri" for product "Tauri" and version "2.0.0" | alpha9 |
Affected
|