CVE-2026-41916 Overview
OpenClaw before version 2026.4.8 contains an authentication state management vulnerability (CWE-613: Insufficient Session Expiration) where the resolvedAuth closure becomes stale after configuration reload. Newly accepted gateway connections continue using outdated resolved auth state, allowing attackers to bypass authentication controls through config reload operations.
Critical Impact
Attackers with low-level privileges can exploit stale authentication state to bypass authentication controls by triggering configuration reload operations, potentially gaining unauthorized access to protected resources.
Affected Products
- OpenClaw versions prior to 2026.4.8
- OpenClaw for Node.js (all versions before the security patch)
Discovery Timeline
- 2026-04-28 - CVE-2026-41916 published to NVD
- 2026-04-30 - Last updated in NVD database
Technical Details for CVE-2026-41916
Vulnerability Analysis
This vulnerability stems from improper session expiration handling in OpenClaw's authentication state management system. When the gateway configuration is reloaded, the resolvedAuth closure retains stale authentication state rather than being refreshed. This creates a race condition where new gateway connections inherit outdated authentication credentials and permissions, effectively allowing users to retain access rights that should have been revoked or modified during the configuration update.
The vulnerability is exploitable over the network but requires an attacker to have some level of prior authentication (low privileges) and depends on the timing of configuration reload operations. This authentication bypass could allow unauthorized access to resources that the attacker should no longer have permission to access after credential changes or permission modifications.
Root Cause
The root cause lies in the DNS pinning and dispatcher creation logic within src/infra/net/fetch-guard.ts. The original implementation resolved pinned hostname information before checking whether a trusted environment proxy was configured. This meant that even when using trusted proxy configurations, the system would retain stale resolved authentication state instead of properly refreshing it after configuration changes.
Attack Vector
The attack vector is network-based and requires the following conditions:
- The attacker must have low-level authenticated access to the OpenClaw system
- A configuration reload must occur (either triggered by the attacker or through normal operations)
- The attacker establishes new gateway connections after the reload while the stale auth state persists
By timing connection attempts around configuration reload events, an attacker can exploit the window where outdated authentication state remains active, bypassing authentication controls that should have been updated.
// Security patch from src/infra/net/fetch-guard.ts
// The fix moves DNS pinning resolution inside the conditional block to prevent stale auth state
try {
assertExplicitProxySupportsPinnedDns(parsedUrl, params.dispatcherPolicy, params.pinDns);
await assertExplicitProxyAllowed(params.dispatcherPolicy, params.lookupFn, params.policy);
- const pinned = await resolvePinnedHostnameWithPolicy(parsedUrl.hostname, {
- lookupFn: params.lookupFn,
- policy: params.policy,
- });
const canUseTrustedEnvProxy =
mode === GUARDED_FETCH_MODE.TRUSTED_ENV_PROXY && hasProxyEnvConfigured();
if (canUseTrustedEnvProxy) {
dispatcher = createHttp1EnvHttpProxyAgent();
} else if (params.pinDns === false) {
dispatcher = createPolicyDispatcherWithoutPinnedDns(params.dispatcherPolicy);
} else {
+ const pinned = await resolvePinnedHostnameWithPolicy(parsedUrl.hostname, {
+ lookupFn: params.lookupFn,
+ policy: params.policy,
+ });
dispatcher = createPinnedDispatcher(pinned, params.dispatcherPolicy, params.policy);
}
Source: GitHub Commit d7c3210
Detection Methods for CVE-2026-41916
Indicators of Compromise
- Unusual authentication patterns immediately following configuration reload events
- Gateway connections established with credentials that were recently revoked or modified
- Log entries showing successful authentication for users whose permissions were changed during config reload
- Anomalous access to protected resources by accounts with recently modified permissions
Detection Strategies
- Monitor configuration reload events and correlate with subsequent authentication activity
- Implement logging to track authentication state changes and identify connections using stale credentials
- Set up alerts for access attempts to resources by users whose permissions were recently modified
- Review gateway connection logs for sessions that span configuration reload events
Monitoring Recommendations
- Enable detailed logging for all configuration reload operations in OpenClaw
- Monitor authentication state transitions during and immediately after configuration changes
- Implement session validation checks that verify authentication state freshness
- Track DNS resolution patterns and dispatcher creation events for anomalies
How to Mitigate CVE-2026-41916
Immediate Actions Required
- Upgrade OpenClaw to version 2026.4.8 or later immediately
- Review recent access logs for potential exploitation during configuration reload windows
- Audit current authentication states and force re-authentication for active sessions if compromise is suspected
- Implement additional session validation checks if immediate patching is not possible
Patch Information
The vulnerability has been addressed in OpenClaw version 2026.4.8. The fix relocates the DNS pinning resolution logic to occur only when needed (inside the conditional block for pinned dispatcher creation), preventing stale authentication state from persisting after trusted environment proxy configurations are applied.
Patch details:
- Commit: d7c3210cd6f5fdfdc1beff4c9541673e814354d5
- Security Advisory: GHSA-68x5-xx89-w9mm
Workarounds
- Minimize configuration reload operations in production environments until patching is complete
- Force session termination and re-authentication after any configuration reload event
- Implement additional authentication validation middleware that verifies credential freshness
- Consider using trusted environment proxy mode consistently to reduce attack surface
# Upgrade OpenClaw to the patched version
npm update openclaw@2026.4.8
# Verify the installed version
npm list openclaw
# Force session refresh after configuration changes (if supported)
openclaw-cli session refresh --all
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

