OSV 1.4.0 · github-reviewed · 修改于 2026-08-04 03:24
发布时间
2026-08-04 03:19
GitHub 审查时间
2026-08-04 03:19
NVD 发布时间
2026-07-30 01:16
源文件
advisories/github-reviewed/2026/08/GHSA-4cwx-7wf7-3272/GHSA-4cwx-7wf7-3272.json
Two issues in undici's cache interceptor, both fixed by the same patch on lib/util/cache.js:
Cache-Control: private directives such as private="" or private="," can be incorrectly stored in the default shared cache, then served to a later caller with the same cache key.private directives in the same header (such as public, max-age=60, private, private="hdr") cause an uncaught TypeError in the cache-control parser, terminating the request.Applications using interceptors.cache() in shared mode may cache a user-specific response and serve it to a later caller with the same cache key. This can disclose private response bodies and headers, including Set-Cookie.
Required conditions:
Cache-Control: public, max-age=300, private="";Vary header.Applications using interceptors.cache() against an upstream that returns a Cache-Control header combining unqualified private with qualified private="..." see an uncaught TypeError: output.private.concat is not a function during response handling. The request rejects; depending on the consumer's error handling, the process may exit.
private="" is parsed as { private: [''] }. The shared-cache guard only rejects private === true, so the response can be stored. When served from cache, the previous user's body and headers may be returned to a different user.
For the crash variant, an unqualified directive sets , then a subsequent qualified directive attempts , which throws because boolean has no method.
privateoutput.private = trueprivate="hdr"output.private.concat(['hdr'])concatThe patch routes the qualified-directive path through a shared helper that normalizes empty-after-trim arrays to true and preserves existing true values, closing both vectors.
Upgrade to undici 7.29.0 or 8.9.0. Both releases fix the qualified private directive handling that caused the shared-cache storage and the parser crash.
Until patched, avoid shared interceptors.cache() for user-specific responses, use type: 'private', or disable caching for affected origins.
Disclosure variant reported by @h0rk1p via HackerOne report #3817497.