Intel

AIKIDO-2026-998551

lightrag-hku is vulnerable to Authentication Bypass

Authentication BypassGHSA-2hjx-23vw-wvw4 Published Today

98

Critical Risk

This Affects:

PYTHONlightrag-hku
1.5.0 - 1.5.4
Fixed in 1.5.5
Are you affected? Scan for Free

TL;DR

The API authentication whitelist matcher in lightrag/api/utils_api.py compares the shipped default WHITELIST_PATHS=/health,/api/* against the full request path including the mount prefix. When LIGHTRAG_API_PREFIX is set to any value beginning with /api (such as the documented /api/v1), every route path starts with /api, so the /api prefix entry matches every request and the whitelist check returns before any credential is examined. Unauthenticated callers can then reach the entire document, query, and graph API, including the destructive DELETE /documents handler, even when both AUTH_ACCOUNTS and LIGHTRAG_API_KEY are configured. The fix resolves the route path with get_route_path, strips the mount prefix before matching, and makes prefix matching segment-aware.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and you set LIGHTRAG_API_PREFIX to a value beginning with /api while relying on the default WHITELIST_PATHS.

Background info

lightrag-hku is vulnerable to Authentication Bypass in versions 1.5.0 - 1.5.4.

How to fix this

Upgrade the lightrag-hku library to the patch version.