0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

[漏洞通告]Apache Tomcat Cluster集群不安全配置导致反序列化远程代码执行漏洞

Last updated at Posted at 2020-05-22

漏洞描述

当Apache Tomcat在集群模式下使用了自带session同步功能,并且没有使用EncryptInterceptor,或者处于不可信的网络环境中,攻击者可能可以构造恶意请求,进行反序列化攻击.该漏洞利用方式已在网络上公开并传播,请广大客户尽快检查conf/server.xml中相关配置.

CVE编号

Apache官方已忽略该漏洞

漏洞威胁等级

高危

影响范围

由于官方忽略该漏洞,全版本Tomcat在不安全配置的情况下均受影响

漏洞验证

由于Tomcat本身的安全性良好,并无除了JDK/JRE以外的gadgets可利用

这里采用JRE8U20的gadget验证
image.png

修复建议

1.若Tomcat启用了session同步功能,配置EncryptInterceptor对通信进行加密(参考文末)
2.禁止Tomcat集群端点对不可信网络开放(只能防范外网攻击,内网依旧有风险,建议监听IP修改为localhost或者127.0.0.1)
3.升级JDK > JDK7U21/JDK8U20

不安全配置参考示例(conf/server.xml):

<Cluster className="org.apache.catalina.ha.tcp.SimpleTcpCluster">
        <Channel className="org.apache.catalina.tribes.group.GroupChannel">
        <Receiver className="org.apache.catalina.tribes.transport.nio.NioReceiver"
                        address="0.0.0.0"
                        port="5000"
                        selectorTimeout="100"
                        maxThreads="6"/>
        </Channel>
</Cluster>

时间轴

[0] 2020/05/22 亚信安全网络攻防实验室分析&复现该漏洞并发布漏洞通告

Reference

http://tomcat.apache.org/tomcat-10.0-doc/config/cluster-interceptor.html#org.apache.catalina.tribes.group.interceptors.EncryptInterceptor_Attributes
https://github.com/threedr3am/tomcat-cluster-session-sync-exp
http://tomcat.apache.org/tomcat-10.0-doc/cluster-howto.html
http://tomcat.apache.org/tomcat-9.0-doc/cluster-howto.html
http://tomcat.apache.org/tomcat-8.5-doc/cluster-howto.html
http://tomcat.apache.org/tomcat-7.0-doc/cluster-howto.html

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?