GHSA-fj7f-vq84-fh43 · Severity: medium · Ecosystem: rubygems — Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile.
`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.
Conclusion & alert: CVE-2021-43809 is rated High Exploit Risk (70.6/100): CVSS Medium severity, with medium exploitation likelihood (EPSS 1.55%). Core evidence: 2 public exploit reference(s) are indexed (Exploit-DB). Mandatory action: Public exploits are available—assess exposure, apply mitigations, and prioritize patching.
Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.
| EDB-ID | Source | Kind | Published | Link |
|---|---|---|---|---|
| — | nvd_ref | exploit_tag | Exploit-DB ↗ | |
| — | nvd_ref | exploit_tag | Exploit-DB ↗ |
EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).
| # | Date | Old EPSS score | New EPSS score | Delta (New - Old) |
|---|---|---|---|---|
| 1 | 2026-04-24 | 1.32% | 1.55% | +0.23% |
| 2 | 2026-04-19 | 1.56% | 1.32% | -0.24% |
| 3 | 2025-12-19 | — | 1.56% | — |
Full EPSS history (30 records total)
CVSS metrics for this CVE.
| Base score | Version | Severity | Vector | Exploitability | Impact | Score source |
|---|---|---|---|---|---|---|
| 6.7 | 3.1 | MEDIUM |
|
0.8 | 5.9 | [email protected] |
| 7.3 | 3.1 | HIGH |
|
1.3 | 5.9 | [email protected] |
| 9.3 | 2.0 | HIGH |
|
8.6 | 10.0 | [email protected] |
GHSA-fj7f-vq84-fh43 · Severity: medium · Ecosystem: rubygems — Local Code Execution through Argument Injection via dash leading git url parameter in Gemfile.
| vendor | priority | summary | link |
|---|---|---|---|
alpine
|
— | CVE-2021-43809: 1 source package rows (ruby-bundler); 1 state rows across 1 repos (3.12-main); fixed 0, open 1. | https://security.alpinelinux.org/vuln/CVE-2021-43809 |
debian
|
not yet assigned | CVE-2021-43809 not yet assigned priority: Debian including 1 source packages (rubygems), 5 status rows across 5 suites (bookworm, bullseye, forky, sid, trixie): resolved 5. | https://security-tracker.debian.org/tracker/CVE-2021-43809 |
gentoo
|
normal | CVE-2021-43809: 1 GLSA(s) (202408-22), 1 atom(s) (dev-ruby/bundler); latest impact normal. | https://bugs.gentoo.org/buglist.cgi?quicksearch=CVE-2021-43809 |
redhat
|
medium | — | https://access.redhat.com/security/cve/CVE-2021-43809 |
suse
|
high | CVE-2021-43809 severity important: SUSE including 268 source package names (2.19-54.2:ruby2.5-rubygem-bundler-1.16.1-150000.3.6.1, 2.5-29.2:ruby2.5-rubygem-bundler-1.16.1-150000.3.6.1, …), 338 product×package rows across 75 product lines (Container bci/ruby, Container suse/rmt-server, … (75 product lines)): Known Affected 231, Fixed 107. | https://www.suse.com/security/cve/CVE-2021-43809/ |
ubuntu
|
medium | CVE-2021-43809 medium priority: Ubuntu including 1 source packages (bundler), 15 status rows across 15 suites (bionic, focal, hirsute, impish, jammy, kinetic, lunar, mantic, noble, oracular, plucky, questing, trusty, upstream, xenial): DNE 9, ignored 2, needed 2, needs-triage 2. | https://ubuntu.com/security/CVE-2021-43809 |