Skip to content

Commit bf33195

Browse files
Add GHSA-m252-9cgf-vx2w for dalli, and update two dalli entries for 5.2.2/5.1.4/5.0.10/4.3.7/3.2.13
GHSA-wr87-m4jw-29x5 and GHSA-w39f-xq2m-4g8x: the first fixes were incomplete; new patched versions and a note on what was missed. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
1 parent 09470c2 commit bf33195

3 files changed

Lines changed: 83 additions & 7 deletions

File tree

‎gems/dalli/GHSA-m252-9cgf-vx2w.yml‎

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
---
2+
gem: dalli
3+
ghsa: m252-9cgf-vx2w
4+
url: https://github.com/petergoldstein/dalli/security/advisories/GHSA-m252-9cgf-vx2w
5+
title: With a namespace, a retried request reads or writes a different key
6+
date: 2026-10-05
7+
description: |
8+
When a client is configured with a `namespace`, a request that hits a
9+
transient network error (a timeout, or a connection closed by memcached
10+
or a proxy, such as stale connections after a memcached restart) was
11+
retried with the namespace applied a second time, so `app:x` became
12+
`app:app:x`. A retried read could return a different key's value, and a
13+
retried write could overwrite a different key. Where cache keys include
14+
user input, a user who can choose a key of the form `app:<something>`
15+
can arrange for another user's retried read to return attacker-chosen
16+
data.
17+
18+
Affected: every single-key operation since 5.0.3, single-server
19+
`get_multi` since 5.1.0, and `get_with_metadata` and `fetch_with_lock`
20+
since 4.1.0. Clients without a namespace are not affected, and 3.2.x is
21+
not affected.
22+
23+
### Workarounds
24+
25+
Don't configure a `namespace`; prefix keys in application code instead.
26+
unaffected_versions:
27+
- "< 4.1.0"
28+
patched_versions:
29+
- "~> 4.3.7"
30+
- "~> 5.0.10"
31+
- "~> 5.1.4"
32+
- ">= 5.2.2"
33+
related:
34+
url:
35+
- https://github.com/petergoldstein/dalli/security/advisories/GHSA-m252-9cgf-vx2w
36+
- https://github.com/petergoldstein/dalli/commit/61a9813
37+
- https://rubygems.org/gems/dalli/versions/5.2.2
38+
- https://github.com/petergoldstein/dalli/releases/tag/v5.2.2
39+
- https://rubygems.org/gems/dalli/versions/5.1.4
40+
- https://github.com/petergoldstein/dalli/releases/tag/v5.1.4
41+
- https://rubygems.org/gems/dalli/versions/5.0.10
42+
- https://github.com/petergoldstein/dalli/releases/tag/v5.0.10
43+
- https://rubygems.org/gems/dalli/versions/4.3.7
44+
- https://github.com/petergoldstein/dalli/releases/tag/v4.3.7
45+
notes: |
46+
- No CVE in GHSA.
47+
- "A CVE has been requested through GitHub but not yet
48+
assigned, so the entry has no cve: field."
49+
- No CVSS score in GHSA; GitHub severity is high.

‎gems/dalli/GHSA-w39f-xq2m-4g8x.yml‎

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,29 @@ description: |
2020
Applications that fork while threads use a shared client are affected
2121
(pre-forking servers, job runners).
2222
23+
The first fix was incomplete on 4.3.6 and 3.2.12: when another
24+
library's fork hook (such as connection_pool's, loaded before Dalli) ran
25+
first in the child, the parent's TLS session could still be ended, and
26+
4.3.6's write buffer kept a reference to the caller's value string with
27+
the meta protocol. Both are fixed in 4.3.7 and 3.2.13.
28+
2329
### Workarounds
2430
2531
Call `close` on Dalli clients before forking, outside any quiet block.
2632
patched_versions:
27-
- "~> 3.2.12"
28-
- "~> 4.3.6"
33+
- "~> 3.2.13"
34+
- "~> 4.3.7"
2935
- "~> 5.0.9"
3036
- "~> 5.1.3"
3137
- ">= 5.2.1"
3238
related:
3339
url:
3440
- https://github.com/petergoldstein/dalli/security/advisories/GHSA-w39f-xq2m-4g8x
3541
- https://github.com/petergoldstein/dalli/commit/62d5ad1
42+
- https://rubygems.org/gems/dalli/versions/4.3.7
43+
- https://github.com/petergoldstein/dalli/releases/tag/v4.3.7
44+
- https://rubygems.org/gems/dalli/versions/3.2.13
45+
- https://github.com/petergoldstein/dalli/releases/tag/v3.2.13
3646
- https://rubygems.org/gems/dalli/versions/5.2.1
3747
- https://github.com/petergoldstein/dalli/releases/tag/v5.2.1
3848
- https://rubygems.org/gems/dalli/versions/5.1.3

‎gems/dalli/GHSA-wr87-m4jw-29x5.yml‎

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,20 +23,37 @@ description: |
2323
to avoid unsafe deserialization. Patched versions add
2424
`Dalli::JSONSerializer`, which reads with `JSON.parse`.
2525
26+
The first fix (5.2.1, 5.1.3, 5.0.9, 4.3.6 and 3.2.12) was incomplete:
27+
on 5.0, 4.3 and 3.2, `cas` and `cas!` (and `fetch_with_lock` on 5.0,
28+
and on 4.3 with the meta protocol) still deserialized values read with
29+
`raw: true`, and on every line but 3.2 a raw read still honored flags a
30+
reply carried unasked. Both are fixed in 5.2.2, 5.1.4, 5.0.10, 4.3.7
31+
and 3.2.13.
32+
2633
### Workarounds
2734
2835
Use a serializer that only parses data, such as one wrapping
2936
`JSON.parse`, instead of `serializer: JSON`.
3037
patched_versions:
31-
- "~> 3.2.12"
32-
- "~> 4.3.6"
33-
- "~> 5.0.9"
34-
- "~> 5.1.3"
35-
- ">= 5.2.1"
38+
- "~> 3.2.13"
39+
- "~> 4.3.7"
40+
- "~> 5.0.10"
41+
- "~> 5.1.4"
42+
- ">= 5.2.2"
3643
related:
3744
url:
3845
- https://github.com/petergoldstein/dalli/security/advisories/GHSA-wr87-m4jw-29x5
3946
- https://github.com/petergoldstein/dalli/commit/8529428
47+
- https://rubygems.org/gems/dalli/versions/5.2.2
48+
- https://github.com/petergoldstein/dalli/releases/tag/v5.2.2
49+
- https://rubygems.org/gems/dalli/versions/5.1.4
50+
- https://github.com/petergoldstein/dalli/releases/tag/v5.1.4
51+
- https://rubygems.org/gems/dalli/versions/5.0.10
52+
- https://github.com/petergoldstein/dalli/releases/tag/v5.0.10
53+
- https://rubygems.org/gems/dalli/versions/4.3.7
54+
- https://github.com/petergoldstein/dalli/releases/tag/v4.3.7
55+
- https://rubygems.org/gems/dalli/versions/3.2.13
56+
- https://github.com/petergoldstein/dalli/releases/tag/v3.2.13
4057
- https://rubygems.org/gems/dalli/versions/5.2.1
4158
- https://github.com/petergoldstein/dalli/releases/tag/v5.2.1
4259
- https://rubygems.org/gems/dalli/versions/5.1.3

0 commit comments

Comments
 (0)