# CVE-2011-2767: Code injection in mod perl 2.0 through 2.0.10

> Attackers can execute arbitrary Perl code via .htaccess files in mod_perl, leading to remote code execution on the Apache server.

- **Severity:** Critical 9.8 (`CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 26 Aug 2018
- **Updated:** 6 Aug 2024
- **Also known as:** DEBIAN-CVE-2011-2767, DLA-1507-1, GHSA-hm7f-5jxx-cwvg, MGASA-2018-0474, RHSA-2018:2737, RHSA-2018:2825, RHSA-2018:2826, SUSE-SU-2019:3213-1, SUSE-SU-2020:14266-1, UBUNTU-CVE-2011-2767, USN-3825-1, openSUSE-SU-2019:2549-1, openSUSE-SU-2019:2558-1

## What is CVE-2011-2767?

CVE-2011-2767 is a critical code injection vulnerability in Canonical Ubuntu Linux, published on 26 Aug 2018. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

mod_perl 2.0 through 2.0.10 allows attackers to execute arbitrary Perl code by placing it in a user-owned .htaccess file, because (contrary to the documentation) there is no configuration option that permits Perl code for the administrator's control of HTTP request processing without also permitting unprivileged users to run Perl code in the context of the user account that runs Apache HTTP Server processes.

Weakness: CWE-94 (Improper Control of Generation of Code)

## Which versions are affected by CVE-2011-2767?

It affects 7 products.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `mod_perl` | Red Hat:enterprise_linux:6::client | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-debuginfo` | Red Hat:enterprise_linux:6::client | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-devel` | Red Hat:enterprise_linux:6::client | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl` | Red Hat:enterprise_linux:6::computenode | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-debuginfo` | Red Hat:enterprise_linux:6::computenode | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-devel` | Red Hat:enterprise_linux:6::computenode | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl` | Red Hat:enterprise_linux:6::server | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-debuginfo` | Red Hat:enterprise_linux:6::server | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-devel` | Red Hat:enterprise_linux:6::server | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl` | Red Hat:enterprise_linux:6::workstation | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-debuginfo` | Red Hat:enterprise_linux:6::workstation | All versions | 0:2.0.4-12.el6_10 |
| `mod_perl-devel` | Red Hat:enterprise_linux:6::workstation | All versions | 0:2.0.4-12.el6_10 |
| `rh-perl524-mod_perl` | Red Hat:rhel_software_collections:3::el6 | All versions | 0:2.0.9-10.el6 |
| `rh-perl524-mod_perl-debuginfo` | Red Hat:rhel_software_collections:3::el6 | All versions | 0:2.0.9-10.el6 |
| `rh-perl524-mod_perl-devel` | Red Hat:rhel_software_collections:3::el6 | All versions | 0:2.0.9-10.el6 |
| `rh-perl524-mod_perl` | Red Hat:rhel_software_collections:3::el7 | All versions | 0:2.0.9-10.el7 |
| `rh-perl524-mod_perl-debuginfo` | Red Hat:rhel_software_collections:3::el7 | All versions | 0:2.0.9-10.el7 |
| `rh-perl524-mod_perl-devel` | Red Hat:rhel_software_collections:3::el7 | All versions | 0:2.0.9-10.el7 |
| `rh-perl526-mod_perl` | Red Hat:rhel_software_collections:3::el7 | All versions | 0:2.0.10-10.el7 |
| `rh-perl526-mod_perl-debuginfo` | Red Hat:rhel_software_collections:3::el7 | All versions | 0:2.0.10-10.el7 |
| `rh-perl526-mod_perl-devel` | Red Hat:rhel_software_collections:3::el7 | All versions | 0:2.0.10-10.el7 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Point of Sale 11 SP3 | All versions | 2.0.4-40.63.3.3 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Server 11 SP4-LTSS | All versions | 2.0.4-40.63.3.3 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Server 12 SP4 | All versions | 2.0.8-13.5.1 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Server 12 SP5 | All versions | 2.0.8-13.5.1 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Server for SAP Applications 12 SP4 | All versions | 2.0.8-13.5.1 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Server for SAP Applications 12 SP5 | All versions | 2.0.8-13.5.1 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Software Development Kit 12 SP4 | All versions | 2.0.8-13.5.1 |
| `apache2-mod_perl` | SUSE:Linux Enterprise Software Development Kit 12 SP5 | All versions | 2.0.8-13.5.1 |
| `apache2-mod_perl` | SUSE:Package Hub 15 | All versions | 2.0.11-bp151.4.3.1 |
| `apache2-mod_perl` | SUSE:Package Hub 15 SP1 | All versions | 2.0.11-bp151.4.3.1 |
| `apache2-mod_perl` | openSUSE:Leap 15.0 | All versions | 2.0.11-lp151.3.3.1 |
| `apache2-mod_perl` | openSUSE:Leap 15.1 | All versions | 2.0.11-lp151.3.3.1 |

Products: Apache Mod Perl, Canonical Ubuntu Linux, Debian Debian Linux, Redhat Enterprise Linux, Redhat Enterprise Linux Desktop, Redhat Enterprise Linux Server, Redhat Enterprise Linux Workstation.

## How do I fix CVE-2011-2767?

Apply the vendor's patch.

## Is CVE-2011-2767 being exploited?

There is no known exploitation of CVE-2011-2767 in the wild and no public exploit code.

## Other vulnerabilities in Canonical Ubuntu Linux

- [CVE-2007-1349](https://insights.sbomify.com/CVE-2007-1349/): Denial of service in n/a (medium 5.0)
- [CVE-2009-0796](https://insights.sbomify.com/CVE-2009-0796/): Cross-site scripting in n/a (low 2.6)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2011-2767 and fix it if it is affected.

What it is: CVE-2011-2767 is a critical code injection vulnerability in Canonical Ubuntu Linux, published on 26 Aug 2018. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2011-2767 in the wild and no public exploit code.

Affected product: Canonical Ubuntu Linux. No package-level version data is available, so check the vendor advisory linked from the reference page.

Task:
1. 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.
2. 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.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2011-2767/ (Markdown: https://insights.sbomify.com/CVE-2011-2767/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2011-2767
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2011-2767
- OSV: https://osv.dev/vulnerability/CVE-2011-2767

---
From sbomify Insights: https://insights.sbomify.com/CVE-2011-2767/
Summaries are generated and may contain mistakes; the official description above is the record.
