Katalog CVE

CVE-2026-48157

ŚrednieCVSS 6.1
Opublikowano: Zaktualizowano: Przetłumaczono: NVD NIST

Prawdopodobieństwo exploitacji (EPSS)

Niskie ryzyko
0.26%

Percentyl 17 - wyżej niż 17% wszystkich znanych CVE

Streszczenie

Slim to mikro framework PHP, który umożliwia tworzenie prostych aplikacji webowych i API. W wersjach od 4.4.0 do 4.15, jeśli aplikacja używa metod HttpException::setTitle() i/lub setDescription() do wprowadzenia danych pochodzących z niezaufanych źródeł, atakujący może wstrzyknąć dowolny kod HTML/JavaScript, który zostanie wykonany w przeglądarce ofiary.

Ocena ryzyka

Podatność ta może prowadzić do ataków typu XSS, co stwarza ryzyko kradzieży danych użytkowników lub przejęcia sesji. Aplikacje, które nie stosują odpowiednich zabezpieczeń, są narażone na wykorzystanie tej luki przez atakujących.

Rekomendacja

Zaleca się aktualizację aplikacji do wersji 4.15.2 lub unikanie przekazywania niezaufanych danych do metod setTitle() i setDescription(). Dodatkowo, warto zarejestrować niestandardowy renderer błędów, który będzie odpowiednio uciekał tytuł i opis.

Oryginalny opis (angielski, źródło NVD)

Slim is a PHP micro framework that enables users to write simple web applications and APIs. In versions 4.4.0 through 4.15, if an application uses HttpException::setTitle() and/or setDescription() to include untrusted/request-derived data in the error title or description (e.g. "No products found matching '{$query}'."), an attacker could inject arbitrary HTML/JavaScript that executes in the victim's browser when they encounter an HTML error page generated by Slim. The vulnerability is present even with displayErrorDetails = false as the unescaped title and description are rendered on this error path. Built-in exceptions (HttpNotFoundException, HttpBadRequestException, etc.) ship plain-text defaults, so a vanilla Slim app with no user code is not exploitable. Only applications that feed untrusted data into setTitle() and/or setDescription() are affected. The issue has been fixed in 4.15.2. If developers are unable to immediately update their applications, they can work around this issue by avoiding passing untrusted/request-derived data into HttpException::setTitle() and setDescription() and using static, plain-text error copy instead. They should also register a custom error renderer (an ErrorRendererInterface implementation, or a subclass of HtmlErrorRenderer that escapes the title and description) for the HTML media type.

Dane podatności pochodzą z NVD (NIST) · CISA KEV · EPSS