CVE-2006-4111: Rails Ruby On Rails Vulnerable To Vulnerability

HIGH
Advisory Identifier: GHSA-rvpq-5xqx-pfpp
CWE-94
Published
Advisory Summary

CVE-2006-4111 is a HIGH ruby on rails vulnerable to vulnerability (CWE-94: Improper Control of Generation of Code ('Code Injection')) affecting Rails libraries in the RubyGems ecosystem. The issue involves ruby on rails vulnerable to code injection. Remediation is available by upgrading affected packages to version 1.1.6.

CVE-2006-4111 at a Glance

CVE Identifier CVE-2006-4111
GHSA Identifier GHSA-rvpq-5xqx-pfpp
Severity HIGH
CVSS v3.1 Base Score N/A
CWE Classification CWE-94: Improper Control of Generation of Code ('Code Injection')
Affected Product Rails
Package Ecosystem RubyGems
Published Date
Last Updated

How to Fix CVE-2006-4111

To remediate this vulnerability, upgrade all affected Rails dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

rails fixed: 1.1.6
Upgrade rails to 1.1.6
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for rails

How to Check if You Are Affected

To determine whether your application is affected by CVE-2006-4111, inspect your project dependencies for Rails:

inspect dependencies for rails

Analyze the terminal output to locate any version of Rails in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 1.1.6), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-94: Improper Control of Generation of Code ('Code Injection'), where the product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment. In Rails, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Ruby on Rails before 1.1.5 allows remote attackers to execute Ruby code with "severe" or "serious" impact via a File Upload request with an HTTP header that modifies the LOAD_PATH variable, a different vulnerability than CVE-2006-4112.

CVE-2006-4111 Affected Rails Versions

1 component(s)
Fixed Versions:
1.1.6
Product / Package Ecosystem Affected Versions Fixed Version
rails
RubyGems
≥ 1.1.0
< 1.1.6
1.1.6

References

Frequently Asked Questions

What is CVE-2006-4111?
CVE-2006-4111 is a security vulnerability in Rails involving Ruby on Rails vulnerable to code injection under CWE-94: Improper Control of Generation of Code ('Code Injection').
Which Rails versions are affected?
Affected versions include releases prior to 1.1.6 across affected packages: rails.
What version fixes CVE-2006-4111?
Upgrading to 1.1.6 (or the latest patched release for your respective branch) resolves the vulnerability.
Is rails affected?
Yes, rails is affected in releases prior to 1.1.6. Upgrade your dependency to 1.1.6 or later.
What CWE is associated with CVE-2006-4111?
CVE-2006-4111 is classified under CWE-94: Improper Control of Generation of Code ('Code Injection') (The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.).
How can I check RubyGems dependencies for CVE-2006-4111?
Run the dependency tree command: 'inspect dependencies for rails'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-rvpq-5xqx-pfpp",
  "modified" : "2025-04-03T14:27:51Z",
  "published" : "2017-10-24T18:33:38Z",
  "aliases" : [ "CVE-2006-4111" ],
  "summary" : "Ruby on Rails vulnerable to code injection",
  "details" : "Ruby on Rails before 1.1.5 allows remote attackers to execute Ruby code with \"severe\" or \"serious\" impact via a File Upload request with an HTTP header that modifies the LOAD_PATH variable, a different vulnerability than CVE-2006-4112.",
  "severity" : [ ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "rails"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "1.1.0"
      }, {
        "fixed" : "1.1.6"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2006-4111"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/presidentbeef/rails-security-history/blob/master/vulnerabilities.md"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/rails/rails"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/rails/CVE-2006-4111.yml"
  }, {
    "type" : "WEB",
    "url" : "https://web.archive.org/web/20200301174340/http://www.securityfocus.com/bid/19454"
  }, {
    "type" : "WEB",
    "url" : "https://web.archive.org/web/20200808083046/http://securitytracker.com/id?1016673"
  }, {
    "type" : "WEB",
    "url" : "http://blog.koehntopp.de/archives/1367-Ruby-On-Rails-Mandatory-Mystery-Patch.html"
  }, {
    "type" : "WEB",
    "url" : "http://weblog.rubyonrails.org/2006/8/9/rails-1-1-5-mandatory-security-patch-and-other-tidbits"
  }, {
    "type" : "WEB",
    "url" : "http://www.gentoo.org/security/en/glsa/glsa-200608-20.xml"
  }, {
    "type" : "WEB",
    "url" : "http://www.novell.com/linux/security/advisories/2006_21_sr.html"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-94" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-06-16T21:56:02Z",
    "nvd_published_at" : "2006-08-14T21:04:00Z"
  }
}