Elastic Elasticsearch
Elasticsearch Groovy Scripting Engine Remote Code Execution Vulnerability
The Groovy scripting engine in Elasticsearch before 1.3.8 and 1.4.x before 1.4.3 allows remote attackers to bypass the sandbox protection mechanism and execute arbitrary shell commands via a crafted script.
Affected versions and mitigation
From the CVE record, GitHub Security Advisories and the vendor's references.Affected
- < 1.3.8
Fixed in 1.3.8
from GitHub Security Advisory GHSA-w94p-6mhw-4qxw
- >= 1.4.0, < 1.4.3
Fixed in 1.4.3
from GitHub Security Advisory GHSA-w94p-6mhw-4qxw
Mitigation
Upgrade org.elasticsearch:elasticsearch to 1.3.8 or later.
Upgrade org.elasticsearch:elasticsearch to 1.4.3 or later.
Timeline
Days relative to CVE publicationFirst public PoC 21 days after publication; added to CISA KEV 7.1 years after publication. First PoC: Metasploit exploit: ElasticSearch Search Groovy Sandbox Bypass (exploit/multi/elasticsearch/search_groovy_script) (Metasploit, 10 Mar 2015).
PoC repositories
Found on GitHub.6 PoCs · 2 pending · 4 suspicious or fake
PoCs 6
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| t0kx/exploit-CVE-2015-1427 | 9 Jan 2017 +1.9 y | 32 | PoC
Flags · score 30
Below the suspicion threshold (50); does not change the assessment. |
| cved-sources/cve-2015-1427 | 6 Jan 2019 +3.9 y | 0 | PoC
Flags · score 30
Below the suspicion threshold (50); does not change the assessment. |
| cyberharsh/Groovy-scripting-engine-CVE-2015-1427 | 22 Jun 2020 +5.3 y | 0 | PoC |
| xpgdgit/CVE-2015-1427 | 29 Jul 2022 +7.4 y | 0 | PoC |
| Sebikea/CVE-2015-1427-for-trixie | 10 Nov 2024 +9.7 y | 0 | PoC via PoC Index |
| CyberCTF/vulhub-elasticsearch-cve-2015-1427 | 8 Oct 2026 +11.6 y | 0 | PoC |
Pending 2
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| gitrobtest/Java-Security | 3 Jul 2017 +2.4 y | 81 | Pending · repository exceeds size limit via PoC Index |
| h3inzzz/cve2015_1427 | unknown | 0 | Pending · repository unavailable (HTTP 404) |
Suspicious or fake 4
| Repository | Created | Stars | Assessment |
|---|---|---|---|
| marcocesarato/Shell-BotKiller | 31 May 2019 +4.3 y | 4 | Fake |
| retr0-13/monkey-auto-pentool | 13 Mar 2022 +7.1 y | 0 | Fake |
| IsmailSoltakhanov17/Monkey | 14 Apr 2022 +7.2 y | 0 | Fake |
| ricardolopezg/backend-swimm | 7 Oct 2022 +7.6 y | 0 | Fake |
Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.
Other public exploits
Exploit-DB, Metasploit and nuclei count as public PoCs. Exploit-tagged references from the CVE record and NVD are links only. None of these are analysed by us.| Source | Title | Published | Found by us |
|---|---|---|---|
| Exploit-DB | ElasticSearch - Remote Code Execution | 11 Mar 2015 | 14 Nov 2026 |
| Exploit-DB | ElasticSearch - Search Groovy Sandbox Bypass (Metasploit) | 16 Mar 2015 | 14 Nov 2026 |
| Metasploit | Metasploit exploit: ElasticSearch Search Groovy Sandbox Bypass (exploit/multi/elasticsearch/search_groovy_script) | 10 Mar 2015 | 14 Nov 2026 |
| nuclei template | nuclei template: ElasticSearch - Remote Code Execution | 27 Apr 2023 | 14 Nov 2026 |
PoC characteristics
What to hunt for in your logs · from 7 PoC reposPOST /_search
- Query
pretty=- Key headers
Accept: */*Accept-Language: en- Body markers
"size""script_fields""lupin""lang":"groovy""script"inapplication/text- Ports
- 9200
- PoC User-Agent
Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0)- Seen in
- 4 repos: CyberCTF/vulhub-elasticsearch-cve-2015-1427, cyberharsh/Groovy-scripting-engine-CVE-2015-1427, t0kx/exploit-CVE-2015-1427, xpgdgit/CVE-2015-1427
- Evidence
- CyberCTF/vulhub-elasticsearch-cve-2015-1427/app/README.md:72 CyberCTF/vulhub-elasticsearch-cve-2015-1427/app/README.zh-cn.md:70 cyberharsh/Groovy-scripting-engine-CVE-2015-1427/README.md:70 t0kx/exploit-CVE-2015-1427/exploit.sh:9 xpgdgit/CVE-2015-1427/CVE-2015-1427.py:51 xpgdgit/CVE-2015-1427/CVE-2015-1427.py:66
POST /website/blog/
- Key headers
Accept: */*Accept-Language: en- Body markers
"name":"test"inapplication/x-www-form-urlencoded- Ports
- 9200
- PoC User-Agent
Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0)- Seen in
- 2 repos: CyberCTF/vulhub-elasticsearch-cve-2015-1427, cyberharsh/Groovy-scripting-engine-CVE-2015-1427
- Evidence
- CyberCTF/vulhub-elasticsearch-cve-2015-1427/app/README.md:55 CyberCTF/vulhub-elasticsearch-cve-2015-1427/app/README.zh-cn.md:53 cyberharsh/Groovy-scripting-engine-CVE-2015-1427/README.md:53
PUT /blog/user/dilbert
- Body markers
"name":"Dilbert Brown"inapplication/x-www-form-urlencoded- Ports
- 9200
- Seen in
- 2 repos: cved-sources/cve-2015-1427, t0kx/exploit-CVE-2015-1427
- Evidence
- cved-sources/cve-2015-1427/build/main.sh:7 t0kx/exploit-CVE-2015-1427/main.sh:10
Regex
Generated from PoC characteristics; not yet reviewed. Matches the request path and query.
(?i)^/_search\?(?:.*&)?pretty=
(?i)^/website/blog/(?:[?#].*)?$
(?i)^/blog/user/dilbert(?:[?#].*)?$
Suricata
Template generated from PoC characteristics. Review before deploying.
alert http any any -> $HOME_NET [9200] (msg:"GG PoC-Monitor CVE-2015-1427 Elastic Elasticsearch exploit attempt"; flow:established,to_server; http.method; content:"POST"; http.uri; content:"/_search"; http.uri; content:"pretty="; http.header; content:"Accept: */*"; nocase; http.header; content:"Accept-Language: en"; nocase; http.request_body; content:"|22|size|22|"; http.request_body; content:"|22|script_fields|22|"; http.request_body; content:"|22|lupin|22|"; http.request_body; content:"|22|lang|22|:|22|groovy|22|"; http.request_body; content:"|22|script|22|"; reference:url,poc.griffinguard.io/cve/CVE-2015-1427; classtype:web-application-attack; sid:9159887; rev:1;)
alert http any any -> $HOME_NET [9200] (msg:"GG PoC-Monitor CVE-2015-1427 Elastic Elasticsearch exploit attempt"; flow:established,to_server; http.method; content:"POST"; http.uri; content:"/website/blog/"; http.header; content:"Accept: */*"; nocase; http.header; content:"Accept-Language: en"; nocase; http.request_body; content:"|22|name|22|:|22|test|22|"; reference:url,poc.griffinguard.io/cve/CVE-2015-1427; classtype:web-application-attack; sid:9624593; rev:1;)
alert http any any -> $HOME_NET [9200] (msg:"GG PoC-Monitor CVE-2015-1427 Elastic Elasticsearch exploit attempt"; flow:established,to_server; http.method; content:"PUT"; http.uri; content:"/blog/user/dilbert"; http.request_body; content:"|22|name|22|:|22|Dilbert Brown|22|"; reference:url,poc.griffinguard.io/cve/CVE-2015-1427; classtype:web-application-attack; sid:9771618; rev:1;)
Sigma
Template generated from PoC characteristics. Review before deploying.
title: Elastic Elasticsearch exploit attempt (CVE-2015-1427)
id: gg-pocmon-cve-2015-1427-9159887
status: experimental
description: Request pattern taken from public PoCs for CVE-2015-1427. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2015-1427
logsource:
category: webserver
detection:
selection:
cs-method: POST
cs-uri-stem|contains|all:
- '/_search'
cs-uri-query|contains|all:
- 'pretty='
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: critical
tags:
- attack.initial_access
- attack.t1190
- cve.2015.1427
title: Elastic Elasticsearch exploit attempt (CVE-2015-1427)
id: gg-pocmon-cve-2015-1427-9624593
status: experimental
description: Request pattern taken from public PoCs for CVE-2015-1427. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2015-1427
logsource:
category: webserver
detection:
selection:
cs-method: POST
cs-uri-stem|contains|all:
- '/website/blog/'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: critical
tags:
- attack.initial_access
- attack.t1190
- cve.2015.1427
title: Elastic Elasticsearch exploit attempt (CVE-2015-1427)
id: gg-pocmon-cve-2015-1427-9771618
status: experimental
description: Request pattern taken from public PoCs for CVE-2015-1427. Generated, not reviewed.
references:
- https://poc.griffinguard.io/cve/CVE-2015-1427
logsource:
category: webserver
detection:
selection:
cs-method: PUT
cs-uri-stem|contains|all:
- '/blog/user/dilbert'
condition: selection
falsepositives:
- Authorized vulnerability scanning
level: critical
tags:
- attack.initial_access
- attack.t1190
- cve.2015.1427