# Kimai: Pre-2FA KIMAI_SESSION cookie grants full authenticated REST API access, bypassing TOTP

High severity, published 2026-07-14. Update kimai/kimai to 2.59.0 or later: composer update kimai/kimai.

Canonical URL: https://buzzphp.com/security/ghsa-v8hx-4vx8-wc96 · Data from GitHub as of 2026-11-25.

| | |
| --- | --- |
| Severity | high |
| Published | 2026-07-14 |
| Updated | 2026-07-14 |
| CVE | [CVE-2026-52827](https://nvd.nist.gov/vuln/detail/CVE-2026-52827) |
| GHSA | [GHSA-v8hx-4vx8-wc96](https://github.com/advisories/GHSA-v8hx-4vx8-wc96) |
| Weakness | CWE-287 |

| Package | Affected versions | Fixed in |
| --- | --- | --- |
| kimai/kimai | < 2.59.0 | 2.59.0 |

## What to do

Update kimai/kimai to 2.59.0 or later: composer update kimai/kimai.

Check which version you run with `composer show kimai/kimai`, and every affected package with `composer audit`.

## About this advisory

Summary Two-factor authentication (TOTP) can be fully bypassed for the REST API. The KIMAISESSION cookie returned in the response to the login request; issued after only the password is verified, before the TOTP step; is already accepted as authenticated by every /api/ endpoint.

So after submitting just the password, the web UI correctly holds the browser at the TOTP screen (/en/auth/2fa), but the cookie from that same login response can be replayed against the API to act as the user without ever entering the second factor. This affects any account with 2FA enabled and requires only the account password.

Details

Affected Component - The API firewall / authorization.



## Links

- [GHSA-v8hx-4vx8-wc96 on GitHub](https://github.com/advisories/GHSA-v8hx-4vx8-wc96)
- [CVE-2026-52827 on the National Vulnerability Database](https://nvd.nist.gov/vuln/detail/CVE-2026-52827)
- [All Composer security advisories](https://buzzphp.com/security)
