🔙 목록으로 돌아가기

CVE-2021-22205: GitLab CE/EE - Remote Code Execution

TitleGitLab CE/EE - Remote Code Execution
AuthorGitLab Red Team
SeverityCritical
ImpactSuccessful exploitation of this vulnerability could allow an attacker to execute arbitrary code on the affected GitLab instance.
RemediationUpgrade to GitLab CE/EE version 13.10.3 or 13.11.1 to mitigate this vulnerability.
CVSS Score10
EPSS Score0.94467
CVE IDCVE-2021-22205
CWE IDCWE-94
Shodan Queryhttp.title:"GitLab"cpe:"cpe:2.3:a:gitlab:gitlab"http.title:"gitlab"
Fofa Querytitle="gitlab"
Tags cve2021 cve kev hackerone gitlab rce vkev vuln

🔍 Vulnerability Description

GitLab CE/EE starting from 11.9 does not properly validate image files that were passed to a file parser, resulting in a remote command execution vulnerability. This template attempts to passively identify vulnerable versions of GitLab without the need for an exploit by matching unique hashes for the application-.css file in the header for unauthenticated requests. Positive matches do not guarantee exploitability. Tooling to find relevant hashes based on the semantic version ranges specified in the CVE is linked in the references section below.

🌐 HTTP Request

GET /users/sign_in HTTP/1.1
Host: www.victim.com
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_5) AppleWebKit/600.2.5 (KHTML, like Gecko) Version/7.1.2 Safari/537.85.11
Connection: close
Accept: */*
Accept-Language: en
Accept-Encoding: gzip

📚 References


🔗 Nuclei Template: https://github.com/packetinside/nuclei-templates/blob/main/http/cves/2021/CVE-2021-22205.yaml

🦈 Packet Capture: ⬇️ Download cve-2021-22205.pcap

⚠️ Notice: These rules are for detection purposes. Please tune them before applying to a production environment.
Snort 2 Rule
N/A
Snort 3 Rule
N/A