Executive brief
AstrBot is a chat-based automation tool. A security flaw in its programming interface (OpenAPI) allows a user with a valid API key to view the chat session history and metadata of other users. By simply providing another person's username, an attacker can bypass security controls to see private session details, potentially leading to further unauthorized access or data exposure.
Technical details
An authorization bypass (CWE-639) exists in AstrBot up to version 4.25.5 within the `OpenApiRoute.get_chat_sessions` function in `astrbot/dashboard/routes/open_api.py`. While the middleware correctly authenticates the API key and enforces the 'chat' scope, the business logic in the session-listing endpoint fails to bind the request to the authenticated principal. Instead, it uses an attacker-controlled `username` query parameter to filter database results. A remote attacker with a valid chat-scope API key can exploit this to retrieve session metadata (IDs, timestamps, and creator names) for any known or guessable username. As of the advisory date, the vendor has not responded to the disclosure.
Affected products
- AstrBotDevs AstrBot <= 4.25.5
Timeline
- 2026-06-09: disclosed: Initial researcher disclosure via GitHub Gist
- 2026-07-18: advisory: CVE published to NVD/VulDB