{"id":"CVE-2022-39215","aliases":["CVE-2022-39215","GHSA-28m8-9j7v-x499","RUSTSEC-2022-0088"],"related":[],"kind":"vulnerability","state":"published","title":"The readDir Endpoint Scope can be Bypassed With Symbolic Links in Tauri","summary":"Tauri is a framework for building binaries for all major desktop platforms. Due to missing canonicalization when `readDir` is called recursively, it was possible to display directory listings outside of the defined `fs` scope. This required a crafted symbolic link or junction folder inside an allowed path of the `fs` scope. No arbitrary file content could be leaked. The issue has been resolved in version 1.0.6 and the implementation now properly checks if the requested (sub) directory is a symbolic link outside of the defined `scope`. Users are advised to upgrade. Users unable to upgrade should disable the `readDir` endpoint in the `allowlist` inside the `tauri.conf.json`.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Tauri is a framework for building binaries for all major desktop platforms. Due to missing canonicalization when `readDir` is called recursively, it was possible to display directory listings outside of the defined `fs` scope. This required a crafted symbolic link or junction folder inside an allowed path of the `fs` scope. No arbitrary file content could be leaked. The issue has been resolved in version 1.0.6 and the implementation now properly checks if the requested (sub) directory is a symbolic link outside of the defined `scope`. Users are advised to upgrade. Users unable to upgrade should disable the `readDir` endpoint in the `allowlist` inside the `tauri.conf.json`.","source":"cvelist"},{"lang":"en","text":"### Impact\nDue to missing canonicalization when `readDir` is called recursively, it was possible to display directory listings outside of the defined `fs` scope. This required a crafted symbolic link or junction folder inside an allowed path of the `fs` scope. No arbitrary file content could be leaked.\n\n\n### Patches\nThe issue has been resolved in https://github.com/tauri-apps/tauri/pull/5123 and the implementation now properly checks if the\nrequested (sub) directory is a symbolic link outside of the defined `scope`.\n\n### Workarounds\nDisable the `readDir` endpoint in the `allowlist` inside the `tauri.conf.json`.\n\n### For more information\n\nThis issue was initially reported by [martin-ocasek]( https://github.com/martin-ocasek) in [#4882](https://github.com/tauri-apps/tauri/issues/4882).\n\nIf you have any questions or comments about this advisory:\n* Open an issue in [tauri](https://github.com/tauri-apps/tauri)\n* Email us at [security@tauri.app](mailto:security@tauri.app)","format":"markdown","source":"ghsa"},{"lang":"en","text":"It is possible for `readDir` to incorrectly enumerate files from a symlinked directory if called recursively when specifying an empty string for the dir parameter as outlined in [this](https://github.com/tauri-apps/tauri/issues/4882) issue.\n\nThis is corrected in [this](https://github.com/tauri-apps/tauri/pull/5123) PR by checking if a directory is a symlink before reading from it.","format":"markdown","source":"rustsec"},{"lang":"es","text":"Tauri es un framework para construir binarios para las principales plataformas de escritorio. Debido a una falta de canonización cuando es llamada recursivamente a \"readDir\", era posible mostrar listados de directorios fuera del ámbito definido de \"fs\". Esto requería un enlace simbólico diseñado o una carpeta de unión dentro de una ruta permitida del ámbito \"fs\". No se podía filtrar contenido de archivos arbitrarios. El problema ha sido resuelto en versión 1.0.6 y la implementación ahora comprueba apropiadamente si el (sub)directorio solicitado es un enlace simbólico fuera del ámbito definido. Es recomendado a usuarios actualizar. Los usuarios que no puedan actualizarse deberán deshabilitar el endpoint \"readDir\" en \"allowlist\" dentro de \"tauri.conf.json\"","source":"nvd"}],"published":"2022-08-07T12:00:00.000Z","modified":"2026-06-17T04:57:55.933Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L","score":8.3,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:L/A:L","score":8.3,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N","score":5.8,"rating":"MEDIUM"},{"scorer":"RustSec Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N","score":5.8,"rating":"MEDIUM"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N","score":5.8,"rating":"MEDIUM"}],"cwes":["CWE-22","CWE-59"],"affected":[{"ranges":[{"version":"< 1.0.6","status":"affected"}],"vendor":"tauri-apps","product":"tauri","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.0.6"}],"ecosystem":"crates.io","package":"tauri","purl":"pkg:cargo/tauri","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0.0.0-0","status":"affected","fixed":"1.0.6"}],"ecosystem":"crates.io","package":"tauri","purl":"pkg:cargo/tauri","source":"rustsec"},{"ranges":[{"status":"affected","fixed":"1.0.6"}],"vendor":"tauri","product":"tauri","cpe":"cpe:2.3:a:tauri:tauri:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/tauri-apps/tauri/security/advisories/GHSA-28m8-9j7v-x499","tags":["mitigation","patch","third-party-advisory","web","x-refsource-confirm","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/tauri-apps/tauri/issues/4882","tags":["exploit","issue-tracking","report","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","rustsec","nvd"]},{"url":"https://github.com/tauri-apps/tauri/pull/5123","tags":["patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/tauri-apps/tauri/pull/5123/commits/1f9b9e8d26a2c915390323e161020bcb36d44678","tags":["patch","third-party-advisory","web","x-refsource-misc","x-transferred"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2022-39215","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/tauri-apps/tauri/commit/bb178829086e80916f9be190f02d83bc25802799","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/tauri-apps/tauri","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/tauri-apps/tauri/releases/tag/tauri-v1.0.6","tags":["web"],"sources":["ghsa"]},{"url":"https://rustsec.org/advisories/RUSTSEC-2022-0088.html","tags":["advisory","web"],"sources":["ghsa","rustsec"]},{"url":"https://crates.io/crates/tauri","tags":["package"],"sources":["rustsec"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"yes","technicalImpact":"partial","date":"2025-04-22T15:39:32.741Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2022-39215","url":"https://www.cve.org/CVERecord?id=CVE-2022-39215","licence":"CVE Terms of Use","modified":"2025-04-22T17:21:33.273Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-28m8-9j7v-x499","url":"https://github.com/advisories/GHSA-28m8-9j7v-x499","licence":"CC-BY-4.0","modified":"2023-11-08T04:10:15.123Z"},{"source":"rustsec","name":"RustSec Advisory Database","id":"RUSTSEC-2022-0088","url":"https://rustsec.org/advisories/RUSTSEC-2022-0088.html","licence":"CC0-1.0","modified":"2023-11-08T04:10:15.123Z"},{"source":"nvd","name":"NVD","id":"CVE-2022-39215","url":"https://nvd.nist.gov/vuln/detail/CVE-2022-39215","licence":"Public domain","modified":"2026-06-17T04:57:55.933Z"}],"updatedAt":"2026-11-25T22:58:14.966Z","epss":{"score":0.01044,"percentile":0.65066,"date":"2026-12-01T12:00:22.000Z"}}