{"id":"CVE-2021-43809","aliases":["ALPINE-CVE-2021-43809","ALSA-2025:7539","BELL-CVE-2021-43809","DEBIAN-CVE-2021-43809","DLA-4163-1","EUVD-2021-2513","GHSA-fj7f-vq84-fh43","MGASA-2022-0102","OESA-2021-1480","OESA-2022-1934","RHSA-2025:7539","RLSA-2025:7539","SUSE-SU-2024:3873-1","SUSE-SU-2026:1355-1","UBUNTU-CVE-2021-43809"],"status":"published","title":"Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","severity":{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.02909,"percentile":0.87082,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-88"],"published":"2021-12-08T18:50:12Z","modified":"2026-11-04T02:30:33Z","fixes":[{"ecosystem":"RubyGems","package":"bundler","fixed_in":["2.2.33"],"sources":["ghsa","osv"]},{"ecosystem":"Alpine:v3.15","package":"ruby-bundler","fixed_in":["2.2.33-r0"],"sources":["osv"]},{"ecosystem":"Debian:12","package":"rubygems","fixed_in":["3.3.5-1"],"sources":["osv"]},{"ecosystem":"Debian:13","package":"rubygems","fixed_in":["3.3.5-1"],"sources":["osv"]},{"ecosystem":"Debian:14","package":"rubygems","fixed_in":["3.3.5-1"],"sources":["osv"]},{"ecosystem":"Mageia:8","package":"ruby","fixed_in":["2.7.5-33.3.mga8"],"sources":["osv"]},{"ecosystem":"openEuler:20.03-LTS-SP1","package":"rubygem-bundler","fixed_in":["2.2.33-1.oe1"],"sources":["osv"]},{"ecosystem":"openEuler:20.03-LTS-SP2","package":"rubygem-bundler","fixed_in":["2.2.33-1.oe1"],"sources":["osv"]},{"ecosystem":"openEuler:20.03-LTS-SP3","package":"rubygem-bundler","fixed_in":["2.2.33-1.oe1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP5","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP6","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server 15 SP2-LTSS","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server 15 SP3-LTSS","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server 15 SP4-LTSS","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 15 SP2","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 15 SP3","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"SUSE:Manager Server 4.3","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]},{"ecosystem":"openSUSE:Leap 15.5","package":"rubygem-bundler","fixed_in":["1.16.1-150000.3.6.1"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"RubyGems","package":"bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.33"}]}]},{"source":"osv","ecosystem":"Alpine:v3.15","package":"ruby-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.33-r0"}]}]},{"source":"osv","ecosystem":"AlmaLinux:8","package":"ruby","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.9-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"ruby-devel","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.9-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"ruby-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.9-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"ruby-irb","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.9-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"ruby-libs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.9-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-abrt","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.3.0-4.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-abrt-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.3.0-4.module_el8.10.0+3871+342e2c2f"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bigdecimal","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.3.4-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bson","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.3.0-2.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bson","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.3.0-2.module_el8.6.0+3170+4b08f9d4"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bson","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.3.0-2.module_el8.5.0+259+8cec6917"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bson-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.3.0-2.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-5.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-bundler-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-5.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-did_you_mean","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.2.0-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-io-console","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.6-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-json","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.1.0-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-minitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"5.10.3-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-mongo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.1-2.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-mongo-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.5.1-2.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-mysql2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.10-4.module_el8.5.0+259+8cec6917"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-mysql2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.10-4.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-mysql2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.10-4.module_el8.6.0+3170+4b08f9d4"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-mysql2-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.4.10-4.module_el8.5.0+2625+ec418553"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-net-telnet","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.1.1-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-openssl","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.1.2-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-pg","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.0.0-3.module_el8.9.0+3635+c6f99506"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-pg-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.0.0-3.module_el8.9.0+3635+c6f99506"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-power_assert","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.1.1-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-psych","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.0.2-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-rake","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"12.3.3-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-rdoc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"6.0.1.1-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-test-unit","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.2.7-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygem-xmlrpc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0.3.0-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygems","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.7.6.3-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"AlmaLinux:8","package":"rubygems-devel","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.7.6.3-114.module_el8.10.0+3991+5e651d4e"}]}],"bundled":2},{"source":"osv","ecosystem":"Debian:12","package":"rubygems","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.3.5-1"}]}]},{"source":"osv","ecosystem":"Debian:13","package":"rubygems","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.3.5-1"}]}]},{"source":"osv","ecosystem":"Debian:14","package":"rubygems","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.3.5-1"}]}]},{"source":"osv","ecosystem":"Debian:11","package":"rubygems","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.2.5-2+deb11u1"}]}],"versions":["3.2.5-2"],"bundled":3},{"source":"osv","ecosystem":"RubyGems","package":"bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.33"}]}],"versions":["0.3.0","0.3.1","0.4.0","0.4.1","0.5.0","0.6.0","0.7.0","0.7.1","0.7.2","0.7.3.pre","0.7.3.pre2","0.8.0","0.8.1","0.9.0","0.9.0.pre1","0.9.0.pre2","0.9.0.pre3","0.9.0.pre4","0.9.0.pre5","0.9.1","0.9.1.pre1","0.9.10","0.9.11","0.9.12","0.9.13","0.9.14","0.9.15","0.9.16","0.9.17","0.9.18","0.9.19","0.9.2","0.9.20","0.9.21","0.9.22","0.9.23","0.9.24","0.9.25","0.9.26","0.9.3","0.9.4","0.9.5","0.9.6","0.9.7","0.9.8","0.9.9","1.0.0","1.0.0.beta.1","1.0.0.beta.10","1.0.0.beta.2","1.0.0.beta.3","1.0.0.beta.4","1.0.0.beta.5","1.0.0.beta.8","1.0.0.beta.9","1.0.0.rc.1","1.0.0.rc.2","1.0.0.rc.3","1.0.0.rc.5","1.0.0.rc.6","1.0.10","1.0.11","1.0.12","1.0.13","1.0.14","1.0.15","1.0.17","1.0.18","1.0.19.rc","1.0.2","1.0.20","1.0.20.rc","1.0.21","1.0.21.rc","1.0.22","1.0.3","1.0.5","1.0.7","1.0.9","1.1.0","1.1.1","1.1.2","1.1.3","1.1.4","1.1.5","1.1.pre","1.1.pre.1","1.1.pre.10","1.1.pre.2","1.1.pre.3","1.1.pre.4","1.1.pre.5","1.1.pre.7","1.1.pre.8","1.1.pre.9","1.1.rc","1.1.rc.2","1.1.rc.3","1.1.rc.5","1.1.rc.6","1.1.rc.7","1.1.rc.8","1.10.0","1.10.0.pre","1.10.0.pre.1","1.10.0.pre.2","1.10.0.rc","1.10.1","1.10.2","1.10.3","1.10.4","1.10.5","1.10.6","1.11.0","1.11.0.pre.1","1.11.0.pre.2","1.11.1","1.11.2","1.12.0","1.12.0.pre.1","1.12.0.pre.2","1.12.0.rc","1.12.0.rc.2","1.12.0.rc.3","1.12.0.rc.4","1.12.1","1.12.2","1.12.3","1.12.4","1.12.5","1.12.6","1.13.0","1.13.0.pre.1","1.13.0.rc.1","1.13.0.rc.2","1.13.1","1.13.2","1.13.3","1.13.4","1.13.5","1.13.6","1.13.7","1.14.0","1.14.0.pre.1","1.14.0.pre.2","1.14.1","1.14.2","1.14.3","1.14.4","1.14.5","1.14.6","1.15.0","1.15.0.pre.1","1.15.0.pre.2","1.15.0.pre.3","1.15.0.pre.4","1.15.1","1.15.2","1.15.3","1.15.4","1.16.0","1.16.0.pre.1","1.16.0.pre.2","1.16.0.pre.3","1.16.1","1.16.2","1.16.3","1.16.4","1.16.5","1.16.6","1.17.0","1.17.0.pre.1","1.17.0.pre.2","1.17.1","1.17.2","1.17.3","1.2.0","1.2.0.pre","1.2.0.pre.1","1.2.0.rc","1.2.0.rc.2","1.2.1","1.2.2","1.2.3","1.2.4","1.2.5","1.3.0","1.3.0.pre","1.3.0.pre.2","1.3.0.pre.3","1.3.0.pre.4","1.3.0.pre.5","1.3.0.pre.6","1.3.0.pre.7","1.3.0.pre.8","1.3.1","1.3.2","1.3.3","1.3.4","1.3.5","1.3.6","1.4.0.pre.1","1.4.0.pre.2","1.4.0.rc.1","1.5.0","1.5.0.rc.1","1.5.0.rc.2","1.5.1","1.5.2","1.5.3","1.6.0","1.6.0.pre.1","1.6.0.pre.2","1.6.0.rc","1.6.0.rc2","1.6.1","1.6.2","1.6.3","1.6.4","1.6.5","1.6.6","1.6.7","1.6.8","1.6.9","1.7.0","1.7.1","1.7.1.pre","1.7.1.pre.2","1.7.1.pre.3","1.7.10","1.7.11","1.7.12","1.7.13","1.7.14","1.7.15","1.7.2","1.7.3","1.7.4","1.7.5","1.7.6","1.7.7","1.7.8","1.7.9","1.8.0","1.8.0.pre","1.8.1","1.8.2","1.8.3","1.8.4","1.8.5","1.8.6","1.8.7","1.8.8","1.8.9","1.9.0","1.9.0.pre","1.9.0.pre.1","1.9.0.rc","1.9.1","1.9.10","1.9.2","1.9.3","1.9.4","1.9.5","1.9.6","1.9.7","1.9.8","1.9.9","2.0.0","2.0.0.pre.1","2.0.0.pre.2","2.0.0.pre.3","2.0.1","2.0.2","2.1.0","2.1.0.pre.1","2.1.0.pre.2","2.1.0.pre.3","2.1.1","2.1.2","2.1.3","2.1.4","2.2.0","2.2.0.rc.1","2.2.0.rc.2","2.2.1","2.2.10","2.2.11","2.2.12","2.2.13","2.2.14","2.2.15","2.2.16","2.2.17","2.2.18","2.2.19","2.2.2","2.2.20","2.2.21","2.2.22","2.2.23","2.2.24","2.2.25","2.2.26","2.2.27","2.2.28","2.2.29","2.2.3","2.2.30","2.2.31","2.2.32","2.2.4","2.2.5","2.2.6","2.2.7","2.2.8","2.2.9"]},{"source":"osv","ecosystem":"Mageia:8","package":"ruby","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.7.5-33.3.mga8"}]}]},{"source":"osv","ecosystem":"openEuler:20.03-LTS-SP1","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.33-1.oe1"}]}]},{"source":"osv","ecosystem":"openEuler:20.03-LTS-SP2","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.33-1.oe1"}]}]},{"source":"osv","ecosystem":"openEuler:20.03-LTS-SP3","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.33-1.oe1"}]}]},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-debugsource","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-devel","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-irb","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-libs","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"ruby-libs-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-abrt","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.3.0-4.module+el8.10.0+22021+135c76a8"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-abrt-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.3.0-4.module+el8.10.0+22021+135c76a8"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bigdecimal","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.3.4-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bigdecimal-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.3.4-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bson","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:4.3.0-2.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bson-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:4.3.0-2.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bson-debugsource","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:4.3.0-2.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bson-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:4.3.0-2.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.16.1-5.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-bundler-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.16.1-5.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-did_you_mean","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.2.0-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-io-console","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.6-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-io-console-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.6-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-json","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.1.0-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-json-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.1.0-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-minitest","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:5.10.3-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-mongo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.1-2.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-mongo-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.1-2.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-mysql2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.10-4.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-mysql2-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.10-4.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-mysql2-debugsource","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.10-4.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-mysql2-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.10-4.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-net-telnet","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.1.1-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-openssl","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.1.2-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-openssl-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.1.2-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-pg","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.0.0-3.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-pg-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.0.0-3.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-pg-debugsource","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.0.0-3.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-pg-doc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.0.0-3.module+el8.9.0+19193+435404ae"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-power_assert","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.1.1-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-psych","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:3.0.2-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-psych-debuginfo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:3.0.2-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-rake","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:12.3.3-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-rdoc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:6.0.1.1-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-test-unit","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:3.2.7-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygem-xmlrpc","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.3.0-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygems","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.7.6.3-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Red Hat:enterprise_linux:8::appstream","package":"rubygems-devel","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.7.6.3-114.module+el8.10.0+23088+750dc6ca"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"ruby","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.9-114.module+el8.10.0+1979+815637df"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-abrt","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.3.0-4.module+el8.5.0+738+032c9c02"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-abrt","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.3.0-4.module+el8.9.0+1536+5f79634e"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-bson","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:4.3.0-2.module+el8.9.0+1536+5f79634e"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.16.1-5.module+el8.10.0+1979+815637df"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-mongo","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:2.5.1-2.module+el8.9.0+1536+5f79634e"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-mysql2","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:0.4.10-4.module+el8.9.0+1536+5f79634e"}]}],"bundled":2},{"source":"osv","ecosystem":"Rocky Linux:8","package":"rubygem-pg","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:1.0.0-3.module+el8.9.0+1536+5f79634e"}]}],"bundled":2},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP5","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP6","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server 15 SP2-LTSS","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server 15 SP3-LTSS","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server 15 SP4-LTSS","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 15 SP2","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server for SAP Applications 15 SP3","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Manager Server 4.3","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"openSUSE:Leap 15.5","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.16.1-150000.3.6.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Module for Basesystem 15 SP7","package":"rubygem-bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"2.2.34-150700.21.3.1"}]}],"bundled":2},{"source":"osv","ecosystem":"Ubuntu:16.04:LTS","package":"bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.10.6-1","1.10.6-2","1.11.2-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.15.1-1","1.16.1-1","1.16.1-1ubuntu0.1~esm1"]},{"source":"osv","ecosystem":"Ubuntu:20.04:LTS","package":"bundler","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.17.3-3","2.1.4-1"]}],"products":[{"vendor":"bundler","product":"bundler"},{"vendor":"rubygems","product":"rubygems"}],"references":[{"url":"https://github.com/rubygems/rubygems/security/advisories/GHSA-fj7f-vq84-fh43","tags":["x_refsource_CONFIRM","x_transferred","Exploit","Vendor Advisory","evidence","web","report"]},{"url":"https://github.com/rubygems/rubygems/pull/5142","tags":["x_refsource_MISC","x_transferred","Patch","fix","web","report"]},{"url":"https://github.com/rubygems/rubygems/commit/0fad1ccfe9dd7a3c5b82c1496df3c2b4842870d3","tags":["x_refsource_MISC","x_transferred","Patch","fix","web","report"]},{"url":"https://github.com/rubygems/rubygems/commit/a4f2f8ac17e6ce81c689527a8b6f14381060d95f","tags":["x_refsource_MISC","x_transferred","Patch","fix","web","report"]},{"url":"https://www.sonarsource.com/blog/securing-developer-tools-package-managers/","tags":["x_refsource_MISC","x_transferred","Exploit","Mitigation","evidence"]},{"url":"https://lists.debian.org/debian-lts-announce/2025/05/msg00015.html","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2021-43809","tags":["advisory"]},{"url":"https://github.com/rubysec/ruby-advisory-db/blob/master/gems/bundler/CVE-2021-43809.yml","tags":["web"]},{"url":"https://www.sonarsource.com/blog/securing-developer-tools-package-managers","tags":["web"]},{"url":"https://github.com/advisories/GHSA-fj7f-vq84-fh43"},{"url":"https://security.alpinelinux.org/vuln/CVE-2021-43809","tags":["advisory"]},{"url":"https://access.redhat.com/errata/RHSA-2025:7539","tags":["advisory"]},{"url":"https://access.redhat.com/security/cve/CVE-2019-19012","tags":["report"]},{"url":"https://access.redhat.com/security/cve/CVE-2021-43809","tags":["report"]},{"url":"https://bugzilla.redhat.com/1802051","tags":["report"]},{"url":"https://bugzilla.redhat.com/2035260","tags":["report"]},{"url":"https://errata.almalinux.org/8/ALSA-2025-7539.html","tags":["advisory"]},{"url":"https://docs.bell-sw.com/security/cves/CVE-2021-43809","tags":["advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2021-43809","tags":["advisory"]},{"url":"https://github.com/rubygems/rubygems","tags":["package"]},{"url":"https://advisories.mageia.org/MGASA-2022-0102.html","tags":["advisory"]},{"url":"https://bugs.mageia.org/show_bug.cgi?id=30162","tags":["report"]},{"url":"https://blog.sonarsource.com/securing-developer-tools-package-managers","tags":["web"]},{"url":"https://www.openeuler.org/en/security/safety-bulletin/detail.html?id=openEuler-SA-2021-1480","tags":["advisory"]},{"url":"https://www.openeuler.org/en/security/safety-bulletin/detail.html?id=openEuler-SA-2022-1934","tags":["advisory"]},{"url":"https://access.redhat.com/security/updates/classification/#moderate","tags":["article"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=1802051","tags":["report"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2035260","tags":["report"]},{"url":"https://security.access.redhat.com/data/csaf/v2/advisories/2025/rhsa-2025_7539.json","tags":["advisory"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2019-19012","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2019-19012","tags":["advisory"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2021-43809","tags":["advisory","report"]},{"url":"https://errata.rockylinux.org/RLSA-2025:7539","tags":["advisory"]},{"url":"https://www.suse.com/support/update/announcement/2024/suse-su-20243873-1/","tags":["advisory"]},{"url":"https://bugzilla.suse.com/1193578","tags":["report"]},{"url":"https://www.suse.com/security/cve/CVE-2021-43809","tags":["web"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-20261355-1/","tags":["advisory"]},{"url":"https://bugzilla.suse.com/1185842","tags":["report"]},{"url":"https://www.suse.com/security/cve/CVE-2020-36327","tags":["web"]},{"url":"https://ubuntu.com/security/CVE-2021-43809","tags":["report"]}],"sources":{"cve":[{"id":"CVE-2021-43809","title":"Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T18:50:12Z","modified":"2026-11-02T18:14:15.426Z","cvss":[{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium","assessor":"cna"}],"cwes":["CWE-88"],"updated_at":"2026-11-02T19:47:06.831391Z"}],"euvd":[{"id":"EUVD-2021-2513","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T18:50:12Z","modified":"2026-11-02T18:14:15Z","cvss":[{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium"}],"updated_at":"2026-11-03T05:08:39.228431Z"}],"ghsa":[{"id":"GHSA-fj7f-vq84-fh43","title":"Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile.","description":"In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false.\n\nTo handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the\ncommands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables.\n\nSince this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\n### Exploitation\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL\nwill be used to construct a Git clone command but will be interpreted as the [upload-pack](https://git-scm.com/docs/git-clone#Documentation/git-clone.txt--ultupload-packgt) argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\n### Impact\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, as explained above, the exploitability is very low, because it requires a lot of user interaction. It still could put developers at risk when dealing with untrusted files in a way they think is safe, because the exploit still works when the victim tries to make sure nothing can happen, e.g. by manually reviewing the `Gemfile` (although they would need the weird URL with a leading dash to not raise any flags).\n\nThis kind of attack vector [has been used in the past](https://www.cnbc.com/2021/01/26/north-korean-hackers-targeting-security-researchers-on-twitter.html) to target security researchers by sending them projects to collaborate on.\n\n### Patches\n\nBundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue.\n\n### Workarounds\n\nRegardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.\n\n### References\n\nhttps://cwe.mitre.org/data/definitions/88.html","status":"published","published":"2021-12-08T19:51:36Z","modified":"2025-11-03T22:27:46Z","cvss":[{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium"}],"cwes":["CWE-88"],"updated_at":"2026-11-02T14:39:05.278442Z"}],"nvd":[{"id":"CVE-2021-43809","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T19:15:10.067Z","modified":"2026-11-02T19:17:45.633Z","cvss":[{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium","assessor":"secondary"},{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high","assessor":"primary"},{"version":"2.0","score":9.3,"vector":"AV:N/AC:M/Au:N/C:C/I:C/A:C","level":"high","assessor":"primary"}],"cwes":["CWE-88"],"updated_at":"2026-11-03T00:01:40.46005Z"}],"osv":[{"id":"ALPINE-CVE-2021-43809","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T19:15:10.067Z","modified":"2026-10-23T17:17:56.223888981Z","cvss":[{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:27:48.646074Z"},{"id":"BELL-CVE-2021-43809","title":"CVE-2021-43809 does not affect BellSoft software","status":"withdrawn","published":"2021-12-08T19:15:00Z","modified":"2026-01-26T10:04:51.178498Z","cvss":[{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:28:16.5265Z"},{"id":"CVE-2021-43809","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T19:15:10.067Z","modified":"2026-11-04T02:30:33.118009263Z","cvss":[{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-04T02:54:44.889498Z"},{"id":"DEBIAN-CVE-2021-43809","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash.  To exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.  This vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T19:15:10.067Z","modified":"2026-11-03T09:47:39.848912226Z","cvss":[{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-03T10:27:58.933618Z"},{"id":"GHSA-fj7f-vq84-fh43","title":"Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile.","description":"In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false.\n\nTo handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the\ncommands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables.\n\nSince this value comes from the `Gemfile` file, it can contain any character, including a leading dash.\n\n### Exploitation\n\nTo exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL\nwill be used to construct a Git clone command but will be interpreted as the [upload-pack](https://git-scm.com/docs/git-clone#Documentation/git-clone.txt--ultupload-packgt) argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside.\n\n### Impact\n\nThis vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, as explained above, the exploitability is very low, because it requires a lot of user interaction. It still could put developers at risk when dealing with untrusted files in a way they think is safe, because the exploit still works when the victim tries to make sure nothing can happen, e.g. by manually reviewing the `Gemfile` (although they would need the weird URL with a leading dash to not raise any flags).\n\nThis kind of attack vector [has been used in the past](https://www.cnbc.com/2021/01/26/north-korean-hackers-targeting-security-researchers-on-twitter.html) to target security researchers by sending them projects to collaborate on.\n\n### Patches\n\nBundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue.\n\n### Workarounds\n\nRegardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.\n\n### References\n\nhttps://cwe.mitre.org/data/definitions/88.html","status":"published","published":"2021-12-08T19:51:36Z","modified":"2026-07-08T06:28:08.542099004Z","cvss":[{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium"}],"cwes":["CWE-88"],"updated_at":"2026-11-02T15:46:46.39441Z"},{"id":"OESA-2021-1480","title":"rubygem-bundler security update","description":"Library and utilities to manage a Ruby application's gem dependencies.\r\n\r\nSecurity Fix(es):\r\n\r\n`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`\u0026apos;s, it is not expected that they lead to execution of external code, unless that\u0026apos;s explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be False. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash. To exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside. This vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`\u0026apos;s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.(CVE-2021-43809)","status":"published","published":"2021-12-31T11:04:45Z","modified":"2026-08-18T01:16:15.474523276Z","cvss":[{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:52:38.987987Z"},{"id":"OESA-2022-1934","title":"rubygem-bundler security update","description":"\r\n\r\nSecurity Fix(es):\r\n\r\n`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`\u0026apos;s, it is not expected that they lead to execution of external code, unless that\u0026apos;s explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash. To exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside. This vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`\u0026apos;s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.(CVE-2021-43809)","status":"published","published":"2022-09-23T11:05:14Z","modified":"2026-08-18T01:17:17.943550777Z","cvss":[{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:52:39.528805Z"},{"id":"RHSA-2025:7539","title":"Red Hat Security Advisory: ruby:2.5 security update","status":"published","published":"2025-05-14T10:06:55Z","modified":"2026-08-07T10:20:33Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-02T15:53:17.133041Z"},{"id":"RLSA-2025:7539","title":"Moderate: ruby:2.5 security update","description":"Ruby is an extensible, interpreted, object-oriented, scripting language. It has features to process text files and to perform system management tasks.\n\nSecurity Fix(es):\n\n* oniguruma: integer overflow in search_in_range function in regexec.c leads to out-of-bounds read (CVE-2019-19012)\n\n* rubygem-bundler: unexpected code execution in Gemfiles (CVE-2021-43809)\n\nFor more details about the security issue(s), including the impact, a CVSS score, acknowledgments, and other related information, refer to the CVE page(s) listed in the References section.","status":"published","published":"2025-07-29T13:38:41.630147Z","modified":"2025-07-29T15:00:09.011622Z","cvss":[{"version":"3.1","score":7.5,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H","level":"high"}],"updated_at":"2026-11-02T15:53:25.508922Z"},{"id":"UBUNTU-CVE-2021-43809","description":"`Bundler` is a package for managing application dependencies in Ruby. In `bundler` versions before 2.2.33, when working with untrusted and apparently harmless `Gemfile`'s, it is not expected that they lead to execution of external code, unless that's explicit in the ruby code inside the `Gemfile` itself. However, if the `Gemfile` includes `gem` entries that use the `git` option with invalid, but seemingly harmless, values with a leading dash, this can be false. To handle dependencies that come from a Git repository instead of a registry, Bundler uses various commands, such as `git clone`. These commands are being constructed using user input (e.g. the repository URL). When building the commands, Bundler versions before 2.2.33 correctly avoid Command Injection vulnerabilities by passing an array of arguments instead of a command string. However, there is the possibility that a user input starts with a dash (`-`) and is therefore treated as an optional argument instead of a positional one. This can lead to Code Execution because some of the commands have options that can be leveraged to run arbitrary executables. Since this value comes from the `Gemfile` file, it can contain any character, including a leading dash. To exploit this vulnerability, an attacker has to craft a directory containing a `Gemfile` file that declares a dependency that is located in a Git repository. This dependency has to have a Git URL in the form of `-u./payload`. This URL will be used to construct a Git clone command but will be interpreted as the upload-pack argument. Then this directory needs to be shared with the victim, who then needs to run a command that evaluates the Gemfile, such as `bundle lock`, inside. This vulnerability can lead to Arbitrary Code Execution, which could potentially lead to the takeover of the system. However, the exploitability is very low, because it requires a lot of user interaction. Bundler 2.2.33 has patched this problem by inserting `--` as an argument before any positional arguments to those Git commands that were affected by this issue. Regardless of whether users can upgrade or not, they should review any untrustred `Gemfile`'s before running any `bundler` commands that may read them, since they can contain arbitrary ruby code.","status":"published","published":"2021-12-08T19:15:00Z","modified":"2025-10-24T04:50:37Z","cvss":[{"version":"3.1","score":6.7,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"medium"},{"version":"3.1","score":7.3,"vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:54:29.220315Z"},{"id":"ALSA-2025:7539","title":"Moderate: ruby:2.5 security update","description":"Ruby is an extensible, interpreted, object-oriented, scripting language. It has features to process text files and to perform system management tasks.  \n\nSecurity Fix(es):  \n\n  * oniguruma: integer overflow in search_in_range function in regexec.c leads to out-of-bounds read (CVE-2019-19012)\n  * rubygem-bundler: unexpected code execution in Gemfiles (CVE-2021-43809)\n\n\nFor more details about the security issue(s), including the impact, a CVSS score, acknowledgments, and other related information, refer to the CVE page(s) listed in the References section.\n","status":"published","published":"2025-05-14T00:00:00Z","modified":"2026-10-29T11:02:23.204505525Z","updated_at":"2026-11-02T15:27:53.448565Z"},{"id":"DLA-4163-1","title":"rubygems - security update","status":"published","published":"2025-05-12T00:00:00Z","modified":"2026-03-09T01:18:59.881661Z","updated_at":"2026-11-02T15:46:12.7027Z"},{"id":"MGASA-2022-0102","title":"Updated ruby packages fix security vulnerability","description":"Command injection in ruby bundler. (CVE-2021-43809)\n","status":"published","published":"2022-03-14T16:51:52Z","modified":"2026-04-16T04:41:36.017688169Z","updated_at":"2026-11-02T15:49:41.849028Z"},{"id":"SUSE-SU-2024:3873-1","title":"Security update for rubygem-bundler","description":"This update for rubygem-bundler fixes the following issues:\n\n- CVE-2021-43809: Fixed remote execution via Gemfile argument injection (bsc#1193578)\n","status":"published","published":"2024-11-01T15:22:19Z","modified":"2026-02-04T04:11:58.303157Z","updated_at":"2026-11-02T15:53:55.639015Z"},{"id":"SUSE-SU-2026:1355-1","title":"Security update for rubygem-bundler","description":"\nThis update for rubygem-bundler fixes the following issues:\n\nUpdated to version 2.2.34.\n\n- CVE-2020-36327: Bundler chooses a dependency source based\n  on the highest gem version number, which means that a rogue gem\n  found at a public source may be chosen (bsc#1185842)\n \n- CVE-2021-43809: rubygem-bundler: remote execution via Gemfile argument injection (bsc#1193578)\n","status":"published","published":"2026-04-15T13:37:50Z","modified":"2026-04-16T08:30:57.106771Z","updated_at":"2026-11-02T15:54:01.262144Z"}]}}
