CVE-2021-22205 — gitlab
CRITICALCVE-2021-22205 is a critical-severity (CVSS 10) Code Injection vulnerability. It is in CISA's Known Exploited Vulnerabilities catalog (added 2021-11-03) and has been used in ransomware campaigns — treat it as actively exploited and patch now. A fix is available — see the affected versions and patch details below.
Exploitation Status
Actively exploited in the wild
- Confirmed by CISA's Known Exploited Vulnerabilities catalog on 2021-11-03 — including use in ransomware campaigns. Federal agencies were required to remediate by 2021-11-17.
- CISA assesses this as automatable — exploitation doesn’t require manual, per-target effort, which raises the odds of mass scanning and opportunistic attacks.
- A successful exploit gives an attacker total control of the affected component, not partial access.
Exploitation and automatability from CISA (KEV catalog and SSVC triage) for CVE-2021-22205.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2021-22205 by exploitation likelihood (EPSS) against impact (CVSS). In the shaded patch-first corner (EPSS 50%+, CVSS 7.0+).
Where this sits among everything scored
Of 394,415 CVEs with a current EPSS score, this one falls in the ≥ 90% band (highlighted). Counts from FIRST.org, log-scaled.
Description
An issue has been discovered in GitLab CE/EE affecting all versions starting from 11.9. GitLab was not properly validating image files that were passed to a file parser which resulted in a remote command execution.
Affected Products
gitlabgitlabResearch use only. For defensive security, authorized penetration testing, and academic research only. Never execute exploit code against systems without explicit written authorization.
GitLab 13.10.2 - Remote Code Execution (RCE) (Unauthenticated)
by Jacob Baines · Nov 17, 2021
Detection & mitigation playbook
VulnerabilityDetect
Identify every host running the affected component and compare the installed build against the fixed version below — for source-built or distro-packaged software the version string, not a lockfile, is the source of truth (`dpkg -l`, `rpm -q`, or the binary's own `--version`).
Fix
Upgrade the affected component to the fixed release for CVE-2021-22205, or apply your distribution's backported patch — distro builds are often patched at an older version number, so check your vendor's advisory rather than the upstream version alone.
Workarounds
Stop passing untrusted input into the interpreter or shell: call the affected binary with an argument array rather than a composed command string, reject anything outside a strict allowlist of expected values, and run the component under an account that cannot reach beyond the work it legitimately does.
How to detect CVE-2021-22205
A community-maintained Nuclei template exists for this CVE. You can scan for it directly:
nuclei -id cve-2021-22205 -u https://target- Template
- GitLab CE/EE - Remote Code Execution
- Severity
- critical
- Impact
- Successful exploitation of this vulnerability could allow an attacker to execute arbitrary code on the affected GitLab instance.
- Remediation
- Upgrade to GitLab CE/EE version 13.10.3 or 13.11.1 to mitigate this vulnerability.
Template by ProjectDiscovery nuclei-templates (GitLab Red Team), MIT licensed. View the full template. Scan only systems you are authorised to test.
Frequently Asked Questions
Is CVE-2021-22205 in your dependencies?
Find it across , including transitive dependencies.