Średnia

Kimai has Server-Side Request Forgery in Invoice PDF Rendering via Markdown Image URLs

  • Ujawniono: 10.07.2026
  • Aktualizacja: 11.10.2026 10:22

Summary

Kimai 2.56.0 contains a server-side request forgery vulnerability in its invoice PDF preview and generation workflow. If an attacker can control Markdown content that is later rendered into an invoice PDF, such as Customer.invoiceText, the server-side PDF renderer will fetch remote image URLs embedded in Markdown image syntax.

This allows the application server to issue outbound requests to attacker-controlled or internal targets during PDF rendering. The behavior can be used for internal network probing, server-side reachability checks, and potentially follow-on exploitation depending on deployment environment and accessible internal services.

Details

The vulnerable behavior occurs in the invoice rendering chain when user-controlled Markdown is transformed into HTML and then rendered by mPDF.

  • First, customer invoice text is copied into the invoice model. . Second, the default PDF invoice template renders that field through the Markdown-to-HTML filter.
  • Third, md2html enables full Markdown rendering.
  • Although safe mode is enabled, the tested Markdown image syntax still survives into the rendered HTML chain in a form that causes the PDF renderer to fetch the image resource.
  • Finally, the HTML is handed to mPDF.

The live test confirms that mPDF attempts to retrieve the remote image URL from the server side during PDF preview. This means the issue is not a template-injection problem but an SSRF condition caused by the rendering pipeline:

  • attacker-controlled Markdown
  • Markdown converted to HTML
  • HTML rendered by mPDF
  • mPDF fetches remote image resources from the server side

A PoC was provided, but removed for security reasons.

Impact

This vulnerability allows an attacker who can influence invoice-rendered Markdown fields to cause the Kimai server to make outbound requests to arbitrary destinations. In real deployments, this can be used to probe internal services, test access to internal administrative or metadata endpoints, and confirm server-side reachability to attacker-controlled infrastructure.

Depending on the environment, SSRF can also become a stepping stone toward more serious outcomes, such as triggering side effects on internal HTTP services or extracting sensitive information from services reachable only by the server. Because invoice generation is commonly performed by administrative or finance-related users, the feature is realistically reachable in business workflows.

Solution

  • Kimai does not allow to use markdown images any longer and converts them to HTML links instead
  • Kimai uses a specialized HttpClient for mPDF (called NoPrivateNetworkHttpClient), which prevents access to a variety of URLs, the full list can be fetched from the documentation
  • This change can be a BC break, if someone used
    • the Kimai domain for hosting invoice or export template images
    • an internal IP for hosting invoice or export template images

See https://www.kimai.org/en/security/ghsa-pj8j-p4g4-4vw8

Czego dotyczy

Kliknij technologię, aby zobaczyć wszystkie dotyczące jej podatności.

PlatformaPaczkaPodatne wersjePoprawka w wersji
Paczka Composer kimai/kimai < 2.58.0 2.58.0

Odnośniki

Ocena CVSS -
Wektor CVSS
CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:N/VA:N/SC:L/SI:N/SA:N
Słabość (CWE)
CWE-918
Platforma
Composer
Paczka
kimai/kimai
Ujawniono
10.07.2026
Aktualizacja
11.10.2026 10:22

Źródła i licencje

OSV / GitHub Advisory Database - GHSA-pj8j-p4g4-4vw8 - CC BY 4.0

Historia podatności: kimai/kimai

Wszystkie opisane podatności tej paczki (Paczka Composer), od najnowszej. Widać, czy to jednorazowa wpadka, czy paczka, której trzeba pilnować.

Wszystkie (33) w archiwum
Wszystkich wpisów
33
Pierwsza → ostatnia
02.2023 07.2026
Bez poprawki
1
Wykorzystywana w atakach
0

Rozkład istotności

  • Krytyczna 2
  • Wysoka 4
  • Średnia 20
  • Niska 7

Ujawnienia w latach

  1. 2023: 2
  2. 2024: 3
  3. 2025: 1
  4. 2026: 27
Istotność:
  1. Kimai has Server-Side Request Forgery in Invoice PDF Rendering via Markdown Image URLs ten wpis
    Średnia CVE-2026-49865 < 2.58.0 2.58.0
  2. Wysoka · 9.8 CVE-2023-53957 <= 1.30.10 brak poprawki
  3. Wysoka · 6.5 ghsa-534c-hcr7-67jg < 2.21.0 2.21.0
  4. Krytyczna · 9.6 CVE-2020-19825 < 1.1 1.1

Dowiedz się, które podatności dotyczą Twojej aplikacji

Po podłączeniu integracji DockRay i włączeniu raportowania oprogramowania DockRay porównuje zgłoszone wersje komponentów ze znanymi podatnościami i powiadamia o potwierdzonych dopasowaniach. Zakres zależy od obsługiwanej technologii i dostępnych biuletynów.

Podłącz swoją aplikację
Newsletter DockRay

Bezpieczeństwo aplikacji w Twojej skrzynce

Najważniejsze podatności, konkretne zalecenia i praktyczne wskazówki dla Twoich aplikacji. Wybierz technologie i śledź to, co ma znaczenie dla Twojego projektu.

  • Codzienne zestawienie nowych podatności, także krytycznych.
  • Powiadomienia o ważnych aktualizacjach.
  • Praktyczne porady o bezpieczeństwie i monitoringu aplikacji.

Pozostaw puste, aby otrzymywać informacje o wszystkich technologiach.

Zapis jest bezpłatny. Wypiszesz się jednym kliknięciem w wiadomości.