Hoch

@angular/common: Weak 32-Bit Cache Key Hashing in `HttpTransferCache` Leading to Cross-Request Data Leakage and State Poisoning

  • Veröffentlicht: 15.06.2026
  • Aktualisiert: 11.10.2026 10:22

Angular's HttpTransferCache caches HTTP requests made during Server-Side Rendering (SSR) so that they can be reused during client-side hydration. This avoids repeating the same HTTP requests on the client. The cached responses are stored in TransferState using a cache key generated by hashing request properties (method, response type, mapped URL, serialized body, and sorted query parameters).

The cache keys are generated using a weak 32-bit DJB2-like polynomial rolling hash. The 32-bit hash space is extremely small, allowing attackers to find hash collisions.

An attacker can easily find a query parameter string (e.g., q=aaCAZMMM for a search request) that produces the exact same 32-bit hash as a sensitive endpoint (e.g., /api/user/profile). When a victim visits a crafted link containing the colliding parameter, the SSR process executes both the search request and the profile request. Due to the hash collision, the search response overwrites the profile response in the TransferState cache.

Impact

When the application attempts to retrieve the cached response for the sensitive endpoint (such as the user's profile), it receives the attacker-controlled response instead. This results in:

  • State Poisoning: The application runs with attacker-forged data, which can lead to bypassing client-side security controls or DOM-based Cross-Site Scripting (XSS) if the data is rendered unsafely.
  • Information Leakage: If the sensitive response is mistakenly associated with the attacker's search results and rendered on the page, the victim's sensitive data may be disclosed to the attacker.

Patched Versions

  • 22.0.1
  • 21.2.17
  • 20.3.25

Framework-Level Fix

The logic has been updated to use a cryptographically secure SHA-256 hash algorithm for generating TransferState cache keys in HttpTransferCache. The cache keys are now 256-bit hexadecimal strings.

Workarounds

If you cannot upgrade immediately, configure your HttpClient requests to skip transfer caching for sensitive endpoints:

ts
this.http.get('/api/user/profile', {
  transferCache: false
});

Alternatively, disable the HTTP transfer cache globally in your application bootstrap config:

ts
import { provideClientHydration, withNoHttpTransferCache } from '@angular/platform-browser';

export const appConfig = {
  providers: [
    provideClientHydration(
      withNoHttpTransferCache()
    )
  ]
};

Credits

This vulnerability was discovered and reported by CodeMender from Google DeepMind.

Betroffene Software

Klicken Sie auf eine Technologie, um alle zugehörigen Schwachstellen anzuzeigen.

PlattformPaketAnfällige VersionenBehoben in
npm-Paket @angular/common >= 22.0.0-next.0, < 22.0.1, >= 21.0.0-next.0, < 21.2.17, >= 20.0.0-next.0, < 20.3.25, <= 19.2.25 22.0.1, 21.2.17, 20.3.25

Verweise

CVSS-Wert 6.1/10
CVSS-Vektor
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
Schwäche (CWE)
CWE-328, CWE-345
Plattform
npm
Paket
@angular/common
Veröffentlicht
15.06.2026
Aktualisiert
11.10.2026 10:22

Quellen und Lizenzen

OSV / GitHub Advisory Database - GHSA-39pv-4j6c-2g6v - CC BY 4.0

Schwachstellenhistorie: @angular/common

Alle veröffentlichten Schwachstellen dieses Pakets (npm-Paket), neueste zuerst. Zeigt, ob es ein einmaliger Ausrutscher ist oder ein Paket, das man im Auge behalten muss.

Einträge insgesamt
8
Erste → letzte
11.2025 10.2026
Ohne Fix
0
In Angriffen ausgenutzt
0

Verteilung nach Schweregrad

  • Hoch 6
  • Mittel 2

Veröffentlichungen pro Jahr

  1. 2025: 1
  2. 2026: 7
  1. Mittel CVE-2026-111753 >= 21.0.0, < 21.0.3, >= 20.0.0, < 20.3.34, <= 19.2.25 21.0.3, 20.3.34
  2. Mittel · 4.0 CVE-2026-88059 >= 22.0.0, < 22.1.1, >= 21.0.0, < 21.2.20, >= 20.0.0, < 20.3.28, <= 19.2.25 22.1.1, 21.2.20, 20.3.28
  3. Hoch CVE-2026-68945 >= 22.0.0-next.0, < 22.0.2, >= 21.0.0-next.0, < 21.2.19, >= 20.0.0-next.0, < 20.3.27, <= 19.2.25 22.0.2, 21.2.19, 20.3.27
  4. Hoch · 7.5 CVE-2026-54268 >= 22.0.0-next.0, < 22.0.1, >= 21.0.0-next.0, < 21.2.17, >= 20.0.0-next.0, < 20.3.25, <= 19.2.25 22.0.1, 21.2.17, 20.3.25
  5. @angular/common: Weak 32-Bit Cache Key Hashing in `HttpTransferCache` Leading to Cross-Request Data Leakage and State Poisoning dieser Eintrag
    Hoch · 6.1 CVE-2026-54266 >= 22.0.0-next.0, < 22.0.1, >= 21.0.0-next.0, < 21.2.17, >= 20.0.0-next.0, < 20.3.25, <= 19.2.25 22.0.1, 21.2.17, 20.3.25
  6. Hoch · 6.1 CVE-2026-50171 >= 22.0.0-next.0, < 22.0.0-rc.2, >= 20.0.0-next.0, < 20.3.22, >= 19.0.0-next.0, < 19.2.23, <= 18.2.14, >= 21.0.0-next.0, < 21.2.15 22.0.0-rc.2, 20.3.22, 19.2.23, 21.2.15
  7. Hoch · 7.5 CVE-2026-50170 >= 22.0.0-next.0, < 22.0.0-rc.2, >= 20.0.0-next.0, < 20.3.22, >= 19.0.0-next.0, < 19.2.23, <= 18.2.14, >= 21.0.0-next.0, < 21.2.15 22.0.0-rc.2, 20.3.22, 19.2.23, 21.2.15
  8. Hoch CVE-2025-66035 >= 21.0.0-next.0, < 21.0.1, >= 20.0.0-next.0, < 20.3.14, < 19.2.16 21.0.1, 20.3.14, 19.2.16

Erkennen Sie Schwachstellen in Ihrer Anwendung

Mit der DockRay-Integration und aktivierter Softwareinventarisierung prüft DockRay gemeldete Komponentenversionen auf bekannte Schwachstellen und benachrichtigt Sie über bestätigte Treffer. Die Abdeckung hängt von der unterstützten Technologie und den verfügbaren Meldungen ab.

Anwendung verbinden
DockRay Newsletter

Anwendungssicherheit in Ihrem Postfach

Wichtige Schwachstellen, konkrete Empfehlungen und praktische Tipps für Ihre Anwendungen. Wählen Sie Ihre Technologien und verfolgen Sie, was für Ihr Projekt relevant ist.

  • Eine tägliche Zusammenfassung neuer Schwachstellen, auch kritischer.
  • Benachrichtigungen über wichtige Updates.
  • Praktische Tipps zur Sicherheit und Überwachung von Anwendungen.

Leer lassen, um Meldungen zu allen Technologien zu erhalten.

Kostenlos anmelden. In jeder E-Mail mit einem Klick abmelden.