# CVE-2016-3714: ImageMagick Improper Input Validation

> Remote attackers can execute arbitrary code via shell metacharacters in crafted images processed by ImageMagick coders.

- **Severity:** High 8.4 (`CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H`)
- **Exploited in the wild:** Yes, since 9 Sep 2024 (CISA KEV)
- **Login needed:** Not needed
- **Attackable:** Local or same network only
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 5 May 2016
- **Updated:** 21 Oct 2025
- **Also known as:** DEBIAN-CVE-2016-3714, GHSA-24cp-26gx-3pp4, SUSE-SU-2016:1301-1, UBUNTU-CVE-2016-3714

## What is CVE-2016-3714?

CVE-2016-3714 is a high-severity command injection vulnerability in Canonical Ubuntu Linux, published on 5 May 2016. It can only be exploited from the same machine or local network, with no action from the victim.

### Official description

The (1) EPHEMERAL, (2) HTTPS, (3) MVG, (4) MSL, (5) TEXT, (6) SHOW, (7) WIN, and (8) PLT coders in ImageMagick before 6.9.3-10 and 7.x before 7.0.1-1 allow remote attackers to execute arbitrary code via shell metacharacters in a crafted image, aka "ImageTragick."

Weakness: CWE-20 (Improper Input Validation)

## Which versions are affected by CVE-2016-3714?

It affects 6 products.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `ImageMagick` | SUSE:Linux Enterprise Server 11 SP2-LTSS | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Linux Enterprise Server 11 SP3-LTSS | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Linux Enterprise Server 11 SP3-TERADATA | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Linux Enterprise Server 11 SP4 | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Linux Enterprise Server for SAP Applications 11 SP4 | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Linux Enterprise Software Development Kit 11 SP4 | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Manager 2.1 | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:Manager Proxy 2.1 | All versions | 6.4.3.6-7.37.1 |
| `ImageMagick` | SUSE:OpenStack Cloud 5 | All versions | 6.4.3.6-7.37.1 |

Products: Canonical Ubuntu Linux, Debian Debian Linux, Imagemagick Imagemagick, Opensuse Leap, Opensuse Opensuse, Suse Suse Linux Enterprise Server.

## How do I fix CVE-2016-3714?

Upgrade to a fixed version. US federal agencies must fix it by 30 Sep 2024.

## Is CVE-2016-3714 being exploited?

Yes. Attackers have exploited CVE-2016-3714 in the wild since at least 9 Sep 2024.

Public exploit code:

- ImaegMagick Code Execution (CVE-2016-3714) (github_poc): https://github.com/Hood3dRob1n/CVE-2016-3714
- https://github.com/jpeanut/ImageTragick-CVE-2016-3714-RShell (github_poc): https://github.com/jpeanut/ImageTragick-CVE-2016-3714-RShell
- Fix ImageMagick Command Injection (CVE-2016-3714) with Ansible. (github_poc): https://github.com/chusiang/CVE-2016-3714.ansible.role
- https://github.com/JoshMorrison99/CVE-2016-3714 (github_poc): https://github.com/JoshMorrison99/CVE-2016-3714
- ImageMagick Delegate Arbitrary Command Execution (metasploit)
- ImageMagick 7.0.1-0 / 6.9.3-9 - 'ImageTragick ' Multiple Vulnerabilities (exploitdb)

## Other vulnerabilities in Canonical Ubuntu Linux

- [CVE-2020-11651](https://insights.sbomify.com/CVE-2020-11651/): SaltStack Salt Authentication Bypass (critical 9.8, exploited in the wild)
- [CVE-2020-7247](https://insights.sbomify.com/CVE-2020-7247/): OpenSMTPD Remote Code Execution (critical 9.8, exploited in the wild)
- [CVE-2019-16928](https://insights.sbomify.com/CVE-2019-16928/): Exim Out-of-bounds Write (critical 9.8, exploited in the wild)
- [CVE-2018-6789](https://insights.sbomify.com/CVE-2018-6789/): Exim Buffer Overflow (critical 9.8, exploited in the wild)
- [CVE-2015-2590](https://insights.sbomify.com/CVE-2015-2590/): Oracle Java SE and Java SE Embedded Remote Code Execution (critical 9.8, exploited in the wild)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2016-3714 and fix it if it is affected.

What it is: CVE-2016-3714 is a high-severity command injection vulnerability in Canonical Ubuntu Linux, published on 5 May 2016. It can only be exploited from the same machine or local network, with no action from the victim.
Exploitation: Yes. Attackers have exploited CVE-2016-3714 in the wild since at least 9 Sep 2024.

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-2016-3714/ (Markdown: https://insights.sbomify.com/CVE-2016-3714/index.md)
```

## Sources

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

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