The vulnerability, CVE-2026-1114, in LoLLMs version 2.1.0 is due to the use of a weak or default secret key for signing JSON Web Tokens (JWTs). This allows an attacker to perform an offline brute-force attack to discover the secret key. With the secret key, an attacker can forge arbitrary JWTs and escalate their privileges to an administrator level.
The analysis of the codebase, specifically the backend/security.py and backend/config.py files, reveals the core components involved in this vulnerability.
The function create_access_token in backend/security.py is responsible for generating JWTs. It uses the SECRET_KEY from the configuration to sign the tokens. The function decode_main_access_token in the same file is responsible for verifying these tokens. Both of these functions are central to the vulnerability, as they perform the cryptographic operations with the potentially weak key.
The patch for this vulnerability was identified in the backend/config.py file. A new function, _ensure_secure_secret_key, was introduced. This function is executed at application startup and checks if the SECRET_KEY is one of several known weak keys (e.g., "changeme", "a_very_secret_key_for_flask_sessions_or_jwt"). If a weak key is detected, the function generates a new, cryptographically secure secret key using secrets.token_urlsafe(32) and persists it in the .env file. This ensures that the application always operates with a strong, unpredictable secret key, thus mitigating the risk of brute-force attacks.
Therefore, the vulnerable functions are create_access_token and decode_main_access_token as they are the ones that would be processing tokens signed with a weak key during an attack. The runtime indicators of exploitation would involve these functions handling forged tokens.