Advisory Database
  • Advisories
  • Dependency Scanning
  1. composer
  2. ›
  3. kimai/kimai
  4. ›
  5. GHSA-rh42-6rj2-xwmc

GHSA-rh42-6rj2-xwmc: Kimai leaks API Token Hash via Invoice Twig Template

April 14, 2026

The Twig sandbox used for invoice templates blocks certain sensitive User methods (password, TOTP secret, etc.) via a blocklist in StrictPolicy::checkMethodAllowed(). However, getApiToken() and getPlainApiToken() are not on the blocklist. An admin who creates an invoice template can embed calls to these methods, causing the bcrypt or sodium hashed API password of any user who generates an invoice using that template to be included in the rendered output.

Only relevant for OnPremise installations with template upload activated.

References

  • github.com/advisories/GHSA-rh42-6rj2-xwmc
  • github.com/kimai/kimai
  • github.com/kimai/kimai/pull/5878
  • github.com/kimai/kimai/security/advisories/GHSA-rh42-6rj2-xwmc

Code Behaviors & Features

Detect and mitigate GHSA-rh42-6rj2-xwmc with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 2.53.0

Fixed versions

  • 2.53.0

Solution

Upgrade to version 2.53.0 or above.

Impact 2 LOW

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

Learn more about CVSS

Weakness

  • CWE-184: Incomplete List of Disallowed Inputs

Source file

packagist/kimai/kimai/GHSA-rh42-6rj2-xwmc.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Fri, 15 May 2026 00:20:11 +0000.