Clarification: 1.3.2 "Sanitized"

Aperta
#3,232 4 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
30/100
Tipo di issue
Documentazione
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
java, javascript, spring

Direzione di ricerca

Inizia leggendo la sorgente .md grezza del requisito 1.3.2 nell’albero di ASVS 5.0, anziché i suoi formati derivati. Esamina come il requisito descrive JavaScript, Spring Expression Language, la sanitization e l’allowlisting; è completato quando la formulazione definisce chiaramente il contesto di esecuzione, il modello di minaccia e le indicazioni di sicurezza previste.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

4a) Waiting for another V1 (prev V5)

1.3.2 Verify that the application avoids the use of eval() or other dynamic code execution features such as Spring Expression Language (SpEL). Where there is no alternative, any user input being included must be sanitized before being executed.

  • Sanitization can lower the chances of an attack succeeding, but it rarely removes the risk completely. Trying to sanitize executable logic is especially risky and often doesn’t work well. In such cases, validation and strict allowlists are the safer choice.
  • The requirement mixes client-side JavaScript concerns with server-side Java expression evaluation into one vague rule, without clarifying the execution context, programming language, or threat model.
  • Sanitization means removing or modifying dangerous input, but it doesn’t guarantee the input will be interpreted safely. AS the application cannot safely “sanitize” arbitrary user input and then pass it to a code interpreter. In dynamic code execution contexts, sanitization can give a false sense of security. A safer approach is to use strict allowlists or context-limited variables.
  • If the term “sanitized” here actually means strict, context-specific allowlisting and tokenization (and not just generic escaping or string cleaning), that needs to be stated clearly, because it’s not obvious to everyone.
Lingua principale
HTML
Stelle
3.8k
Fork
855
Merge medio
1g 9h
PR unite (30g)
8

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di OWASP/ASVS

Tutte le issue di OWASP/ASVS

Issue simili

Altre issue su Documentation

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.