字号·· | 护眼
漏洞档案 · 严重

Jenkins Script Security Plugin 沙箱绕过(CVE-2019-1003029)

CVE-2019-1003029 别名:GHSA-XVXQ-HQ48-XPHM
CVSS 9.9 / 3.1 EPSS 74.4% CISA KEV 在野利用 公开 PoC · 1
综合风险86/ 100
CVSS9.9严重
EPSS74.4%30 天利用概率
机构收录时间2019-03-09更新 2026-12-01

研判简报

概述

Jenkins Script Security Plugin 在解析、编译与脚本实例化阶段未应用沙箱保护,攻击者提供特制 Groovy 脚本即可绕过沙箱。仅需 Overall/Read 权限即可在 Jenkins 控制器 JVM 上执行任意代码。官方公告指出同一缺陷还影响 workflow-cps、matrix-project、email-ext、groovy、job-dsl 等使用相关 API 的插件。拥有 Jenkins 只读账号或可控制流水线/任务配置的场景应优先关注。

严重性

CVSS 3.1 评分 9.9(critical),综合风险分 88.49/100;攻击面为经脚本执行与脚本校验 HTTP 端点的沙箱逃逸,最终导致控制器完全失陷。

利用状态

CISA KEV 已收录(收录日期 2022-04-25,要求动作期限 2022-05-16);存在 Exploit-DB/公开 PoC(1 条),参考链接含 Metasploit 模块。CISA SSVC:automatable=no、exploitation=active、technical_impact=total。EPSS 30 天利用概率 74.4%(百分位 99.5%)。以上核查日期均为 2026-11-24。材料未给出勒索软件关联信息与 Nuclei 模板状态。

受影响产品

Jenkins Script Security Plugin 1.53 及更早版本;组件涉及 GroovySandbox.java、SecureGroovyScript.java。官方公告同时点名 workflow-cps、matrix-project、email-ext、groovy、job-dsl 等插件受同类沙箱绕过影响。部署形态为 Jenkins 控制器(公告原文称 controller,旧称 master)。

修复版本

材料未给出具体修复版本号;官方公告仅说明 Script Security Plugin 已在上述阶段新应用沙箱保护,并弃用 GroovySandbox#run(Script, Whitelist)、新增 GroovySandbox#run(GroovyShell, String, Whitelist) 与 GroovySandbox#checkScriptForCompilationErrors(String, GroovyClassLoader)。KEV 要求按厂商说明应用更新。

缓解措施

无法立即升级时:收紧 Overall/Read 权限,避免向不可信用户授予只读账号;限制可编辑流水线、Job DSL、Matrix 配置及邮件扩展模板的人员范围;禁用或限制脚本校验 HTTP 端点的外部访问;关注系统日志中关于已弃用 API 的警告。材料未给出其他官方缓解方案。

响应步骤

  1. 盘点 Script Security Plugin 版本是否 ≤1.53,并同步核查 workflow-cps、matrix-project、email-ext、groovy、job-dsl 等插件。
  2. 按厂商说明升级相关插件至已应用沙箱保护的版本。
  3. 审计拥有 Overall/Read 及可配置流水线/任务脚本的账号,清理冗余授权。
  4. 检查控制器日志与历史构建,排查可疑 Groovy 脚本执行及异常进程。
  5. 若无法及时升级,按缓解措施临时收紧权限与端点暴露面,并记录例外。

参考来源

  1. https://nvd.nist.gov/vuln/detail/CVE-2019-1003029kev
  2. https://jenkins.io/security/advisory/2019-03-06/#SECURITY-1336%20%281%29x_refsource_CONFIRM,x_refsource_CONFIRM,x_transferred,advisory,euvd
  3. http://www.securityfocus.com/bid/107476vdb-entry,x_refsource_BID,vdb-entry,x_refsource_BID,x_transferred,advisory,euvd
  4. https://access.redhat.com/errata/RHSA-2019:0739vendor-advisory,x_refsource_REDHAT,vendor-advisory,x_refsource_REDHAT,x_transfer
  5. http://packetstormsecurity.com/files/166778/Jenkins-Remote-Code-Execution.htmlx_refsource_MISC,x_refsource_MISC,x_transferred,advisory,euvd
  6. https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2019-1003029government-resource
  7. https://github.com/rapid7/metasploit-framework/tree/master/modules/exploit_multi/http/jenkins_metaprogrammingexploit,metasploit
  8. https://www.lacework.com/blog/spytech-necro-keksecs-latest-python-malware/kev
  9. https://euvd.enisa.europa.eu/enisa/EUVD-2022-5866kev
  10. https://www.cisa.gov/known-exploited-vulnerabilities-catalogkev
  11. https://vulncheck.com/kev/cve-2019-1003029advisory,vulncheck_kev
  12. https://euvd.enisa.europa.eu/vulnerability/EUVD-2022-5866advisory,euvd