Informazioni sul CVE-2023-29008

SvelteKit framework has Insufficient CSRF protection for CORS requests

CWE ID: CWE-918

Base Score (CVSS): N/A

CVE: CVE-2023-29008

Descrizione: The SvelteKit framework offers developers an option to create simple REST APIs. This is done by defining a `+server.js` file, containing endpoint handlers for different HTTP methods. SvelteKit provides out-of-the-box cross-site request forgery (CSRF) protection to its users. The protection is implemented at `kit/src/runtime/server/respond.js`. While the implementation does a sufficient job of mitigating common CSRF attacks, the protection can be bypassed in versions prior to 1.15.2 by simply specifying an upper-cased `Content-Type` header value. The browser will not send uppercase characters, but this check does not block all expected CORS requests. If abused, this issue will allow malicious requests to be submitted from third-party domains, which can allow execution of operations within the context of the victim’s session, and in extreme scenarios can lead to unauthorized access to users’ accounts. This may lead to all POST operations requiring authentication being allowed in the following cases: If the target site sets `SameSite=None` on its auth cookie and the user visits a malicious site in a Chromium-based browser; if the target site doesn’t set the `SameSite` attribute explicitly and the user visits a malicious site with Firefox/Safari with tracking protections turned off; and/or if the user is visiting a malicious site with a very outdated browser. SvelteKit 1.15.2 contains a patch for this issue. It is also recommended to explicitly set `SameSite` to a value other than `None` on authentication cookies especially if the upgrade cannot be done in a timely manner.

Vettore di attacco CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H

Punteggio CVSS

Il CVSS è un sistema di valutazione che misura la gravità di una vulnerabilità informatica considerando fattori come l’impatto potenziale, la probabilità di attacco e la facilità di esecuzione.

Punteggio Base (calcolato da AziendaSicura): 8.7 (High)

Riassunto: Accesso: Network, Privilegi: None, Interazione utente: Required, Confidenzialità: High, Integrità: High, Disponibilità: High.

Dettaglio del Vettore

Metrica Valore Significato Descrizione
Attack Vector (AV) N Network L’attacco può essere eseguito da remoto attraverso la rete.
Attack Complexity (AC) L Low L’attacco non richiede condizioni particolari.
Privileges Required (PR) N None Non sono richiesti privilegi.
User Interaction (UI) R Required È richiesta l’interazione di un utente.
Scope (S) U Unchanged Il raggio d’azione non cambia.
Confidentiality Impact (C) H High Grave impatto sulla riservatezza.
Integrity Impact (I) H High Grave impatto sull’integrità.
Availability Impact (A) H High Rende il sistema inutilizzabile.

Riferimenti esterni

Prodotti interessati

  • sveltejs – kit

Relazioni con altri prodotti

Produttore:sveltejs
Prodotto: kit
Anno: 2023
CWE: CWE-918
CVSS: 0.0