{"id":"CVE-2025-59349","published":"2025-09-17T19:41:03Z","modified":"2025-09-18T17:35:48Z","title":"Directories created via os.MkdirAll are not checked for permissions","vendor":"dragonflyoss","product":"dragonfly","tier":"tail","description":{"text":"Dragonfly is an open source P2P-based file distribution and image acceleration system. Prior to 2.1.0, DragonFly2 uses the os.MkdirAll function to create certain directory paths with specific access permissions. This function does not perform any permission checks when a given directory path already exists. This allows a local attacker to create a directory to be used later by DragonFly2 with broad permissions before DragonFly2 does so, potentially allowing the attacker to tamper with the files. This vulnerability is fixed in 2.1.0.","provenance":"source","from":"CVE.org"},"cvss":{"score":2,"severity":"LOW","version":"4.0","vector":"CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:P","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00171,"percentile":0.03715,"provenance":"source"},"cwes":[{"id":"CWE-732","name":"Incorrect Permission Assignment for Critical Resource"}],"references":[{"url":"https://github.com/dragonflyoss/dragonfly/security/advisories/GHSA-8425-8r2f-mrv6","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/dragonflyoss/dragonfly/blob/main/docs/security/dragonfly-comprehensive-report-2023.pdf","tags":["x_refsource_MISC"]}],"priority":{"score":2.1,"factors":[{"name":"EPSS percentile","points":0.74},{"name":"CVSS severity","points":1.4}]},"vendorSlug":"dragonflyoss","affectedVersions":[{"vendor":"dragonflyoss","product":"dragonfly","versions":["< 2.1.0"]}],"ssvc":{"exploitation":"none","automatable":"no","technicalImpact":"partial","timestamp":"2025-09-18T17:35:44.011716Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Go","package":"github.com/dragonflyoss/dragonfly","vulnerableRanges":["<2.1.0","all versions"],"patched":["2.1.0"],"from":["GHSA-8425-8r2f-mrv6","GO-2025-3964"],"provenance":"source"},{"ecosystem":"Go","package":"d7y.io/dragonfly/v2","vulnerableRanges":["<2.1.0"],"patched":["2.1.0"],"from":["GHSA-8425-8r2f-mrv6","GO-2025-3964"],"provenance":"source"}],"summary":{"text":"Dragonfly (dragonflyoss) has a flaw in its directory creation logic, where DragonFly2 uses os.MkdirAll to create certain directory paths with specific permissions without checking permissions when the path already exists. An attacker with local access and no privileges, requiring no user interaction, can pre-create a directory that Dragonfly later uses with broader permissions, potentially allowing them to tamper with the files stored there.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T22:23:52Z"},"euvd":{"id":"EUVD-2025-29775","exploited":false,"provenance":"source"}}