Severity:

HIGH RISK

(8.2)

Missing Access Control in lollms_generation_events

CVE-2026-1117

Deferred

Vulnerability type

Category:

Missing Access Control

CWE:

CWE-284

Impact:

Unauthenticated Abuse of Resource-Intensive Operations and Shared State Corruption

Severity:

HIGH RISK

(8.2)

CVSS version:

3.0

Catch this CVE while code is being written

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

Summary

The lollms_generation_events.py module in parisneo/lollms 5.9.0 exposes Socket.IO events like generate_text and cancel_generation without any authentication or authorization checks.

Unauthenticated clients can trigger resource-intensive or state-altering operations, leading to denial of service, corruption of shared state, and race conditions in multi-client environments.

Affected context

This vulnerability affects deployments of parisneo/lollms that:

  • Expose the Socket.IO server publicly or to untrusted networks
  • Use the lollms_generation_events.py component to register generation-related events
  • Rely on lollmsElfServer.busy and lollmsElfServer.cancel_gen global flags to coordinate text generation across clients

In such contexts, any network client capable of connecting to the Socket.IO endpoint can invoke sensitive events without passing through an access control layer.

Exploit preconditions

  • Attack surface: Socket.IO event interface exposed by the lollms server.
  • Required access: Ability to establish a Socket.IO connection to the server (no authentication required in the vulnerable configuration).
  • Trigger point: Invocation of events such as generate_text, generate_msg, generate_msg_from, or cancel_generation.
  • Why exploitation is possible: The add_events function binds event handlers without wrapping them in authentication/authorization logic, and shared global flags are used to coordinate server state across all clients, allowing one client's calls to affect others.

Why this happens

The core issue is missing access control on server-side event handlers, mapped to CWE-284: Improper Access Control.

Sensitive Socket.IO events that trigger computationally expensive generation or mutate shared state are registered directly without verifying the identity or privileges of the caller.

Additionally, the use of global flags (lollmsElfServer.busy, lollmsElfServer.cancel_gen) to manage multi-client state introduces an insecure concurrency pattern: state is global and not scoped to individual sessions or users, so actions from one client can override or disrupt operations belonging to other clients.

Potential impact

  • Unauthenticated clients may exhaust CPU/GPU resources by repeatedly triggering generation events, leading to denial of service.
  • One client can cancel or interfere with other clients' ongoing generations via shared global flags.
  • Inconsistent or corrupted application state can occur due to race conditions in global state management.
  • Service reliability and availability can be degraded under low-effort automated abuse (e.g., simple scripts or bots).
  • Loss of integrity of user sessions, as operations are not isolated per user or per connection.

General mitigation guidance

Effective mitigation focuses on adding robust access control and eliminating insecure shared state patterns:

  • Introduce an authentication layer for Socket.IO connections (e.g., tokens, sessions, or API keys) and ensure every event handler validates identity before performing work.
  • Apply authorization checks on each sensitive event (generate_text, generate_msg, generate_msg_from, cancel_generation) so that only permitted users or roles can trigger expensive or disruptive operations.
  • Scope state to user, session, or connection instead of using process-wide global flags; encapsulate generation state in per-client objects or contexts.
  • Implement rate limiting and quotas at the event level to constrain how frequently expensive operations can be invoked from a single client or IP.
  • Design the system with fail-safe defaults, where events are inaccessible unless explicit access controls grant permission.

How teams detect issues like this

Detection can rely on both code-level and operational signals:

  • Static analysis and code review:
  • Flag event handlers or Socket.IO callbacks that do not reference any authentication or authorization checks.
  • Identify usage of global or module-level flags and variables controlling cross-client behavior (e.g., busy, cancel_gen) as indicators of unsafe shared state.
  • Enforce policies that sensitive operations (generation, cancellation, administrative actions) must check caller identity and permissions.
  • Automated tooling:
  • Use application security scanners and linters configured with rules for missing access control on network-exposed endpoints and event handlers.
  • Integrate CI checks that search for unprotected event registrations in files like *_events.py.
  • Runtime monitoring:
  • Monitor for abnormal volume of generation events from unauthenticated or single-origin clients.
  • Alert when cancellation events are being triggered disproportionately relative to legitimate user activity.

Sources

SourceLink
github.comgithub.com/parisneo/lollms/commit/36a5b513dfefe9c2913bf9b618457b4fea603e3b
huntr.comhuntr.com/bounties/d2846a7f-0140-4105-b1bb-5ef64ec8b829

Frequently asked

questions

Yes. If the Socket.IO endpoint is reachable over the network and no external gateway enforces authentication, remote clients can connect and invoke the exposed events without credentials.

No. In the vulnerable configuration, any client that can establish a Socket.IO connection to the server can trigger the sensitive events, regardless of user identity or privilege level.

The most robust fix is to place all Socket.IO event handlers behind a consistent authentication and authorization layer, and to refactor server state so that generation and cancellation flags are scoped per user or per connection rather than being global.

Adopt a design policy that treats every network-exposed handler (HTTP, WebSocket, Socket.IO) as untrusted by default, requiring explicit access control; avoid global, cross-client state for mutable runtime flags; and include security reviews and automated checks specifically for missing authentication/authorization logic and unsafe shared state in new event handlers.

Find out what's already
exploitable in your codebase.