当前位置:首页 > 安全预警 > 正文

Apache Shiro远程代码执行漏洞预警

发布时间:2019-11-15 20:38:40,来源:中国信息通信研究院

      一、基本情况

Apache Shiro存在远程代码执行漏洞。攻击者通过使用有效的rememberMe cookie作为Padding Oracle攻击的前缀,然后构造rememberMe来执行Java反序列化攻击,最终可导致远程代码执行。

      二、攻击原理

Apache Shiro是一个强大且易用的Java安全框架,用于执行身份验证、授权、密码和会话管理。   

Apache Shiro cookie中的通过AES-128-CBC模式加密的rememberMe字段存在问题,容易受到Padding Oracle攻击。

整个过程攻击者无需知道RememberMe的加密密钥。并通过以下步骤发起攻击:

1) 登录网站,并从cookie中获取rememberMe

2) 使用rememberMe cookie作为Padding Oracle攻击的前缀

3) 通过Padding Oracle攻击加密一条ysoserial(知名的Java反序列化验证和利用工具)中的Java序列化Payload来构造恶意rememberMe

4) 使用刚刚构造的恶意rememberMe重新请求网站,进行反序列化攻击,最终导致远程代码执行

      三、影响范围

受影响版本:

Apache Shiro 1.2.5

Apache Shiro 1.2.6

Apache Shiro 1.3.0

Apache Shiro 1.3.1

Apache Shiro 1.3.2

Apache Shiro 1.4.0-RC2

Apache Shiro 1.4.0

Apache Shiro 1.4.1

      四、处置建议

目前此漏洞暂无补丁和缓解方案,建议在外部设备尝试拦截爆破流量。

      五、参考链接

1) https://issues.apache.org/jira/browse/SHIRO-721