跳到正文
V2EX·· 3 天前AI 评分47

旧版本 Node.js 如何应对 HTTP/2 Shell 漏洞(CVE-2026-111497)

旧版本 nodejs 如何修复 HTTP2Shell 漏洞 (CVE-2026-111497)

AI 导读

Node.js 官方发布漏洞更新,CVE-2026-111497 涉及 Brotli 解码器越界写入,可能导致远程代码执行,官方建议升级至 Node.js v24.22。对于暂时无法升级的旧版本环境,文章询问能否通过 Istio 网关拒绝带有 `Content-Encoding: br` 的请求作为应对方案。

正文

2026 年 10 月 26 ,nodejs 官方发布了新的漏洞更新版本 ( https://nodejs.org/en/blog/vulnerability/october-2026-security-releases ,里面最严重的应该算这个 Node.js Brotli decoder out-of-bounds write permits remote code execution (CVE-2026-111497) - (high)。 官方解决方案是升级到 nodejs v24.22 ,如果生产环境版本低于 22 比如是 18.18 ,而且近期也不能直接升级到最新版本的话,你们有啥解决方案吗? 直接网关上拒绝压缩请求,比如 istio 上加 rule 是否可以?以下是 rule 的 example:

apiVersion: security.istio.io/v1
kind: AuthorizationPolicy
metadata:
  name: deny-brotli-request
  namespace: istio-system
spec:
  selector:
    matchLabels:
      app: istio-ingressgateway
  action: DENY
  rules:
    - when:
        - key: request.headers[content-encoding]
          values:
            - "br"

来源:V2EX · v2ex.com