{"id":"CVE-2021-41089","published":"2021-10-04T20:20:15Z","modified":"2024-08-04T02:59:31Z","title":"`docker cp` allows unexpected chmod of host files","vendor":"moby","product":"moby","tier":"tail","description":{"text":"Moby is an open-source project created by Docker to enable software containerization. A bug was found in Moby (Docker Engine) where attempting to copy files using `docker cp` into a specially-crafted container can result in Unix file permission changes for existing files in the host’s filesystem, widening access to others. This bug does not directly allow files to be read, modified, or executed without an additional cooperating process. This bug has been fixed in Moby (Docker Engine) 20.10.9. Users should update to this version as soon as possible. Running containers do not need to be restarted.","provenance":"source","from":"CVE.org"},"cvss":{"score":2.8,"severity":"LOW","version":"3.1","vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:C/C:L/I:N/A:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.0029,"percentile":0.14136,"provenance":"source"},"cwes":[{"id":"CWE-281","name":"Improper Preservation of Permissions"}],"references":[{"url":"https://github.com/moby/moby/security/advisories/GHSA-v994-f8vw-g7j4","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/moby/moby/commit/bce32e5c93be4caf1a592582155b9cb837fc129a","tags":["x_refsource_MISC"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/ZNFADTCHHYWVM6W4NJ6CB4FNFM2VMBIB/","tags":["vendor-advisory","x_refsource_FEDORA"]},{"url":"https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/B5Q6G6I4W5COQE25QMC7FJY3I3PAYFBB/","tags":["vendor-advisory","x_refsource_FEDORA"]},{"url":"https://cert-portal.siemens.com/productcert/pdf/ssa-222547.pdf","tags":["x_refsource_CONFIRM"]}],"priority":{"score":4.8,"factors":[{"name":"EPSS percentile","points":2.83},{"name":"CVSS severity","points":1.96}]},"vendorSlug":"moby","affectedVersions":[{"vendor":"moby","product":"moby","versions":["< 20.10.9"]}],"affected":[{"ecosystem":"Go","package":"github.com/docker/docker","vulnerableRanges":["<20.10.9","<20.10.9+incompatible"],"patched":["20.10.9","20.10.9+incompatible"],"from":["GHSA-v994-f8vw-g7j4","GO-2024-2913"],"provenance":"source"},{"ecosystem":"Go","package":"github.com/moby/moby","vulnerableRanges":["<20.10.9+incompatible"],"patched":["20.10.9+incompatible"],"from":["GO-2024-2913"],"provenance":"source"}],"summary":{"text":"The vulnerability is in the moby product's Docker Engine (moby), specifically in the docker cp command, where copying files into a specially crafted container can cause Unix file permission changes on existing files in the host's filesystem, broadening access for other users. An attacker needs local access with low privileges, and exploitation requires a cooperating process; the flaw does not by itself allow files to be read, modified, or executed.","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T22:19:18Z"},"euvd":{"id":"EUVD-2024-2176","exploited":false,"provenance":"source"},"lineage":{"familyId":"fam-moby-cve-2019-14271","parents":[{"from":"CVE-2019-14271","to":"CVE-2021-41089","relation":"related","confidence":"medium","kind":"lineage","evidence":[{"kind":"same-code","provenance":"machine","files":["pkg/chrootarchive/archive.go"],"commits":["https://github.com/moby/moby/commit/11e48badcb67554b3d795241855028f28d244545","https://github.com/moby/moby/commit/fa8dd90ceb7bcb9d554d27e0b9087ab83e54bd2b","https://github.com/moby/moby/commit/bce32e5c93be4caf1a592582155b9cb837fc129a"],"basis":"rarely changed file"}]}],"packageHistory":[{"cve":"CVE-2019-14271","published":"2019-07-29","fixed":"20.10.0-beta1+incompatible","kev":false},{"cve":"CVE-2021-21284","published":"2021-02-02","fixed":"20.10.3","kev":false},{"cve":"CVE-2021-21285","published":"2021-02-02","fixed":"20.10.3","kev":false},{"cve":"CVE-2021-41089","published":"2021-10-04","fixed":"20.10.9+incompatible","kev":false},{"cve":"CVE-2021-41091","published":"2021-10-04","fixed":"20.10.9+incompatible","kev":false,"link":{"from":"CVE-2021-41091","to":"CVE-2021-41089","relation":"successor","confidence":"medium","kind":"sequence","orderedBy":"description","evidence":[{"kind":"version-step","provenance":"source","package":"Go:github.com/moby/moby","fromFixed":"20.10.9","toFixed":"20.10.9+incompatible","daysApart":0},{"kind":"similar","provenance":"machine","score":0.27,"basis":"same product + CWE + description similarity"}]}},{"cve":"CVE-2022-24769","published":"2022-03-24","fixed":"20.10.14+incompatible","kev":false,"link":{"from":"CVE-2021-41089","to":"CVE-2022-24769","relation":"successor","confidence":"low","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Go:github.com/docker/docker","fromFixed":"20.10.9+incompatible","toFixed":"20.10.14","daysApart":171},{"kind":"version-step","provenance":"source","package":"Go:github.com/moby/moby","fromFixed":"20.10.9+incompatible","toFixed":"20.10.14","daysApart":171}]}},{"cve":"CVE-2024-24557","published":"2024-02-01","fixed":"25.0.2+incompatible","kev":false}],"package":"Go:github.com/moby/moby"}}