{"answers":{"affected":"2 open source packages ship an affected version, including bundler. It affects 1 product.","exploited":"There is no known exploitation of CVE-2019-3881 in the wild and no public exploit code.","fix":"Upgrade bundler to 2.1.0 or later.","what":"CVE-2019-3881 is a high-severity path traversal vulnerability in rubygem-bundler, published on 4 Sep 2020. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link."},"fix_prompt":"Check this codebase for CVE-2019-3881 and fix it if it is affected.\n\nWhat it is: CVE-2019-3881 is a high-severity path traversal vulnerability in rubygem-bundler, published on 4 Sep 2020. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.\nExploitation: There is no known exploitation of CVE-2019-3881 in the wild and no public exploit code.\n\nAffected packages and fixed versions:\n- bundler (RubyGems): affected from 1.14.0; fixed in 2.1.0\n- bundler (RubyGems): affected from 1.14.0; fixed in 2.1.0\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2019-3881/ (Markdown: https://insights.sbomify.com/CVE-2019-3881/index.md)","id":"CVE-2019-3881","markdown":"https://insights.sbomify.com/CVE-2019-3881/index.md","name":"CVE-2019-3881","record":{"aliases":["GHSA-g98m-96g9-wfjq","OESA-2021-1419","SUSE-SU-2020:1582-1","SUSE-SU-2020:1582-2","UBUNTU-CVE-2019-3881","USN-4870-1","openSUSE-SU-2020:0803-1","openSUSE-SU-2020:0861-1"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["code_execution"],"network_reachable":"adjacent_or_local","non_default_config":true,"product_category":"Ruby dependency manager","requires_auth":"none","summary":"An attacker can execute malicious code by placing files in a predictable temporary directory when the user's home directory is not writable.","user_interaction":"required","vuln_class":"path_traversal"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"redhat","cpe":[{"product":"bundler","vendor":"bundler"}],"cvss":{"score":7.8,"severity":"high","source":"nvd","vector":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-427","name":"Uncontrolled Search Path Element"}],"description":"Bundler prior to 2.1.0 uses a predictable path in /tmp/, created with insecure permissions as a storage location for gems, if locations under the user's home directory are not available. If Bundler is used in a scenario where the user does not have a writable home directory, an attacker could place malicious code in this directory that would be later loaded and executed.","ecosystems":["RubyGems","SUSE:Linux Enterprise Module for Basesystem 15 SP1","SUSE:Linux Enterprise Module for Basesystem 15 SP2","openSUSE:Leap 15.1","openSUSE:Leap 15.2"],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"Insecure path handling in Bundler","id":"CVE-2019-3881","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"RubyGems","product":null,"products":[],"type":"path_traversal","year":"2019"},"n_packages":6,"n_references":1,"next":{"headline":"Denial of service in kernel","id":"CVE-2019-3882"},"packages":[{"ecosystem":"RubyGems","fixed":["2.1.0"],"introduced":["1.14.0"],"last_affected":[],"package":"bundler","purl":null,"source":"GHSA-g98m-96g9-wfjq"},{"ecosystem":"RubyGems","fixed":["2.1.0"],"introduced":["1.14.0"],"last_affected":[],"package":"bundler","purl":"pkg:gem/bundler","source":"GHSA-g98m-96g9-wfjq"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP1","fixed":["1.16.1-3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-bundler","purl":"pkg:rpm/suse/rubygem-bundler\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP1","source":"SUSE-SU-2020:1582-1"},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP2","fixed":["1.16.1-3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-bundler","purl":"pkg:rpm/suse/rubygem-bundler\u0026distro=SUSE%20Linux%20Enterprise%20Module%20for%20Basesystem%2015%20SP2","source":"SUSE-SU-2020:1582-2"},{"ecosystem":"openSUSE:Leap 15.1","fixed":["1.16.1-lp151.3.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-bundler","purl":"pkg:rpm/opensuse/rubygem-bundler\u0026distro=openSUSE%20Leap%2015.1","source":"openSUSE-SU-2020:0803-1"},{"ecosystem":"openSUSE:Leap 15.2","fixed":["1.16.1-lp152.4.3.1"],"introduced":["0"],"last_affected":[],"package":"rubygem-bundler","purl":"pkg:rpm/opensuse/rubygem-bundler\u0026distro=openSUSE%20Leap%2015.2","source":"openSUSE-SU-2020:0861-1"}],"prev":{"headline":"Path traversal in samba","id":"CVE-2019-3880"},"products":["rubygem-bundler"],"published":"2020-09-04","related":[{"cvss_score":9.8,"headline":"Bundler allows attacker to inject arbitrary code via secondary Gem source","id":"CVE-2016-7954","kev_date_added":null,"published":"2016-12-22"},{"cvss_score":8.8,"headline":"Dependency Confusion in Bundler","id":"CVE-2020-36327","kev_date_added":null,"published":"2021-04-29"},{"cvss_score":6.7,"headline":"Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile","id":"CVE-2021-43809","kev_date_added":null,"published":"2021-12-08"},{"cvss_score":5,"headline":"Bundler may install gems from a different source than expected","id":"CVE-2013-0334","kev_date_added":null,"published":"2014-10-31"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CC BY 4.0","name":"SUSE","prefix":"SUSE"},{"class":"attribution","licence":"CC BY 4.0","name":"SUSE","prefix":"openSUSE"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","updated":"2024-08-04","vendors":["n/a"]},"summary":"An attacker can execute malicious code by placing files in a predictable temporary directory when the user's home directory is not writable.","url":"https://insights.sbomify.com/CVE-2019-3881/"}