/

CVE-2026-58473

Severity:

CRITICAL RISK

(9.1)

Broken Access Control (CWE-306) in Cognee LLM Settings

CVE-2026-58473

Deferred

Vulnerability type

Category:

Broken Access Control

CWE:

CWE-306, CWE-862

Impact:

Instance-Wide Data Exfiltration and Service Hijack

Severity:

CRITICAL RISK

(9.1)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Cognee contains a broken access control flaw that lets any self-registered user modify the global LLM provider configuration without admin checks.

When exploited, all instance-wide LLM traffic can be redirected to an attacker-controlled endpoint, exposing prompts, uploaded documents, and knowledge graph data from other users.

Affected context

This vulnerability occurs in Cognee deployments where:

  • User self-registration is enabled or possible
  • The settings endpoint is exposed to authenticated users without role checks
  • A process-wide singleton cache stores the global LLM provider configuration

Under these conditions, any non-privileged user who can reach the settings API may overwrite the shared configuration, affecting all users in that instance.

Exploit preconditions

  • Attack surface: HTTP API settings endpoint used to manage LLM provider configuration
  • Required access: Ability to create a standard user account via self-registration and send authenticated requests to the settings endpoint
  • Trigger point: Calling the configuration update operation on the settings endpoint, which lacks admin or superuser authorization checks
  • Why exploitation is possible: The endpoint trusts any authenticated user and writes directly to a process-wide singleton configuration cache, so changes instantly affect all LLM operations across the instance

Why this happens

The underlying bug is a classic broken access control issue mapped to CWE-306 (Missing Authentication for Critical Resource) and CWE-862 (Missing Authorization).

A security-sensitive operation—editing global LLM provider settings—is exposed via an API that performs no role-based authorization or privilege check beyond basic authentication.

Because the application stores LLM configuration in a shared singleton cache, there is no per-tenant isolation; a single unauthorized write modifies behavior for all users, enabling redirection of model traffic and unintended disclosure of user data flowing through the LLM.

Potential impact

  • Attackers may redirect all LLM requests to an attacker-controlled endpoint
  • Attackers can exfiltrate prompts, uploaded documents, extracted entities, and knowledge graph content from all users
  • Attackers could tamper with LLM responses, leading to data poisoning or misinformation
  • Attackers may disrupt service availability by pointing the LLM provider configuration to invalid or unstable endpoints
  • Attackers can degrade user trust by silently observing or manipulating sensitive workloads processed by the LLM

General mitigation guidance

Effective mitigation focuses on enforcing strict access control around global configuration and reducing the blast radius of misconfiguration.

Common defensive patterns include:

  • Treating configuration management endpoints as privileged operations, guarded by explicit admin or superuser role checks
  • Applying role-based access control (RBAC) and least privilege, so standard users cannot modify instance-wide settings
  • Introducing configuration scoping or tenant isolation instead of process-wide singletons for multi-user environments
  • Validating configuration changes through server-side policies (e.g., allowlisted provider domains, transport security requirements)
  • Logging and monitoring configuration changes, with alerting on unexpected or non-admin modifications

How teams detect issues like this

Organizations can detect similar broken access control issues by:

  • Performing static analysis focused on endpoints that write to configuration objects, checking for missing authorization gates or role checks
  • Reviewing API controllers and service layers for operations that modify global or shared state without explicit privilege verification
  • Enforcing architectural policies that require security annotations or middleware for administrative functionality
  • Using automated security testing tools (DAST/SAST) and authorization-focused test cases to simulate low-privilege attempts to change settings
  • Auditing runtime logs for configuration changes initiated by non-admin accounts or unusual traffic patterns to new LLM endpoints

Sources

SourceLink
github.comgithub.com/topoteretes/cognee/commit/d10b1b77e2157c6238fd4d1acb1923a048991699
github.comgithub.com/topoteretes/cognee/issues/3084
github.comgithub.com/topoteretes/cognee/releases/tag/v1.2.0
vulncheck.comvulncheck.com/advisories/cognee-unauthorized-llm-configuration-overwrite-via-api-v1-settings

Frequently asked

questions

In affected Cognee instances, any attacker who can self-register and reach the settings endpoint can exploit it. Because the configuration is global, a single successful exploit impacts all users on that instance.

Only standard authenticated user access is needed. The attacker does not require admin or superuser privileges, because the settings endpoint lacks authorization checks for configuration updates.

Restrict configuration management operations to clearly defined administrative roles, enforce RBAC on the settings endpoint, and ensure that any write to global or shared configuration objects passes through robust authorization logic.

Treat global configuration as a critical resource, apply least privilege and role separation, avoid process-wide singletons for multi-tenant environments, and incorporate security reviews or automated checks focused on access control for administrative APIs.

Find out what's already
exploitable in your codebase.