NetSight
hoch7.5

CVE-2022-39261

Twig may load a template outside a configured directory when using the filesystem loader

Auswirkung

# Description When using the filesystem loader to load templates for which the name is a user input, it is possible to use the `source` or `include` statement to read arbitrary files from outside the templates directory when using a namespace like `@somewhere/../some.file` (in such a case, validation is bypassed). # Resolution We fixed validation for such template names. Even if the 1.x branch is not maintained anymore, a new version has been released. # Credits We would like to thank Dariusz Tytko for reporting the issue and Fabien Potencier for fixing the issue.

Ein Angreifer kann die Lücke über das Netzwerk ausnutzen, ohne Anmeldung, ohne Zutun eines Nutzers. Bei Erfolg: hohes Risiko, dass Daten ausgelesen werden.

Betroffene Pakete

ÖkosystemPaketBetroffenBehoben in
composertwig/twig>= 1.0.0, < 1.44.71.44.7

Betroffene Produkte

HerstellerProduktBetroffene Versionen
DebianDebian Linux
Versionen 10.0, 11.0
DrupalDrupal
ab 8.0.0 vor 9.3.22
ab 9.4.0 vor 9.4.7
FedoraprojectFedora
Versionen 35, 36, 37
SymfonyTwig
ab 1.0.0 vor 1.44.7
ab 2.0.0 vor 2.15.3
ab 3.0.0 vor 3.4.3

Schwachstellenklasse

Referenzen