CVE-2022-41874: Tauri Tauri Filesystem Scope Can Be Vulnerability
LOWCVE-2022-41874 is a LOW (CVSS 2.3) tauri filesystem scope can be vulnerability (CWE-284: Improper Access Control) affecting Tauri libraries in the crates.io ecosystem. The issue involves tauri filesystem scope can be partially bypassed. Remediation is available by upgrading affected packages to version 1.0.7, 1.1.2.
CVE-2022-41874 at a Glance
Security Impact
CVSS: 2.3
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:N/A:N).
How to Fix CVE-2022-41874
To remediate this vulnerability, upgrade all affected Tauri dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade Tauri to 1.0.7
Upgrade Tauri to 1.1.2
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for Tauri
How to Check if You Are Affected
To determine whether your application is affected by CVE-2022-41874, inspect your project dependencies for Tauri:
inspect dependencies for Tauri
Analyze the terminal output to locate any version of Tauri in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.0.7), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-284: Improper Access Control, where the product does not restrict or incorrectly restricts access to a resource from an unauthorized actor. In Tauri, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2022-41874 Affected Tauri Versions
2 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
Tauri
|
crates.io |
≥ 1.0.0
< 1.0.7
|
1.0.7
|
|
Tauri
|
crates.io |
≥ 1.1.0
< 1.1.2
|
1.1.2
|
References
Frequently Asked Questions
What is CVE-2022-41874?
Which Tauri versions are affected?
What version fixes CVE-2022-41874?
Is Tauri affected?
What is the CVSS score of CVE-2022-41874?
What CWE is associated with CVE-2022-41874?
How can I check crates.io dependencies for CVE-2022-41874?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-q9wv-22m9-vhqh",
"modified" : "2023-02-28T16:52:02Z",
"published" : "2022-11-08T17:33:26Z",
"aliases" : [ "CVE-2022-41874" ],
"summary" : "Tauri Filesystem Scope can be Partially Bypassed",
"details" : "### Impact\n\nDue to incorrect escaping of special characters in paths selected via the file dialog and drag and drop functionality, it was possible to partially bypass the `fs` scope definition. It was not possible to traverse into arbitrary paths, as the issue was limited to neighboring files and sub folders of already allowed paths.\n\nThe impact differs on Windows, MacOS and Linux due to different specifications of valid path characters.\n\nOn Linux or MacOS based systems it was possible to use the `*`, `**` and `[a-Z]` patterns inside a path, which allowed to read the content of sub directories and single character files in a folder, where only specific files or the directory itself were allowed.\n\nOn Windows `[a-Z]` was the possible bypass pattern, as `*` is not treated as a valid path component. This implies that only single character files inside an already allowed directory were unintentionally accessible.\n\nThis bypass depends on the file picker dialog or dragged files, as user selected paths are automatically added to the allow list at runtime.\n\nA successful bypass requires the user to select a pre-existing malicious file or directory during the file picker dialog and an adversary controlled logic to access these files. This means the issue by itself can not be abused and requires further intentional or unintentional privileges.\n\n### Workaround\n\nDisable the `dialog` and `fileDropEnabled` component inside the `tauri.conf.json`.\n\n### Patches\n\nThe issue has been resolved in #5237 and the implementation now properly escapes the special characters. The patch has been included in releases: `1.0.7`, `1.1.2` and `1.2.0`\n\n### For more information\n\nThis issue was initially reported by MessyComposer in #5234.\n\nIf you have any questions or comments about this advisory:\n\nOpen an issue in tauri\nEmail us at security@tauri.app",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:L/AC:H/PR:H/UI:R/S:C/C:L/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "Tauri"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.0.0"
}, {
"fixed" : "1.0.7"
} ]
} ]
}, {
"package" : {
"ecosystem" : "crates.io",
"name" : "Tauri"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.1.0"
}, {
"fixed" : "1.1.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/tauri-apps/tauri/security/advisories/GHSA-q9wv-22m9-vhqh"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-41874"
}, {
"type" : "WEB",
"url" : "https://github.com/tauri-apps/tauri/issues/5234"
}, {
"type" : "WEB",
"url" : "https://github.com/tauri-apps/tauri/pull/5237"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/tauri-apps/tauri"
}, {
"type" : "WEB",
"url" : "https://rustsec.org/advisories/RUSTSEC-2022-0091.html"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-284" ],
"severity" : "LOW",
"github_reviewed" : true,
"github_reviewed_at" : "2022-11-08T17:33:26Z",
"nvd_published_at" : "2022-11-10T21:15:00Z"
}
}