/

CVE-2026-119407

Severity:

HIGH RISK

(7.1)

CSRF (CWE-352) in Element Web and Desktop Sessions

CVE-2026-119407

Awaiting Analysis

Vulnerability type

Category:

Cross-Site Request Forgery

CWE:

CWE-352

Impact:

Session disruption and local data loss

Severity:

HIGH RISK

(7.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

Element Web and Element Desktop may accept guest credentials supplied through URL fragment parameters when loading a session. An attacker can trick a logged-in user into opening a crafted link, potentially forcing a guest session, logging the user out, and clearing locally stored data or unbacked end-to-end encryption keys.

Element Web and Element Desktop may accept guest credentials supplied through URL fragment parameters when loading a session. An attacker can trick a logged-in user into opening a crafted link, potentially forcing a guest session, logging the user out, and clearing locally stored data or unbacked end-to-end encryption keys.

Affected context

The issue occurs in Element Web and Element Desktop deployments that use the affected session-loading behavior and process guest credentials from URL fragments. Risk increases when a logged-in user opens an attacker-controlled link and locally stored encryption keys are not backed up or synchronized elsewhere.

The issue occurs in Element Web and Element Desktop deployments that use the affected session-loading behavior and process guest credentials from URL fragments. Risk increases when a logged-in user opens an attacker-controlled link and locally stored encryption keys are not backed up or synchronized elsewhere.

Exploit preconditions

  • Attack surface: Web or desktop session-loading functionality
  • Required access: No authenticated access to the target account is required
  • Trigger point: A logged-in user opens a crafted link containing guest session parameters
  • Why exploitation is possible: The application may trust URL fragment values as guest credentials and replace the active session without sufficient user intent or origin validation
  • Attack surface: Web or desktop session-loading functionality
  • Required access: No authenticated access to the target account is required
  • Trigger point: A logged-in user opens a crafted link containing guest session parameters
  • Why exploitation is possible: The application may trust URL fragment values as guest credentials and replace the active session without sufficient user intent or origin validation

Why this happens

The underlying issue is a cross-site request forgery pattern in session state management. The application accepts attacker-influenced URL fragment parameters and uses them to alter the user's active session, rather than treating the data as untrusted and requiring an explicit, validated transition.

This maps to CWE-352: Cross-Site Request Forgery, where an attacker causes a user's browser or client to perform an unintended state-changing action using the user's existing session context.

The underlying issue is a cross-site request forgery pattern in session state management. The application accepts attacker-influenced URL fragment parameters and uses them to alter the user's active session, rather than treating the data as untrusted and requiring an explicit, validated transition.

This maps to CWE-352: Cross-Site Request Forgery, where an attacker causes a user's browser or client to perform an unintended state-changing action using the user's existing session context.

Potential impact

  • Forced logout from the legitimate user session
  • Clearing of local application stores
  • Loss of unbacked end-to-end encryption keys
  • Temporary denial of access to locally available conversations or data
  • User confusion, disruption, or social-engineering impact
  • Forced logout from the legitimate user session
  • Clearing of local application stores
  • Loss of unbacked end-to-end encryption keys
  • Temporary denial of access to locally available conversations or data
  • User confusion, disruption, or social-engineering impact

General mitigation guidance

Mitigation generally focuses on preventing URL-controlled data from silently changing authenticated session state.

Common defensive patterns include:

  • Do not accept guest credentials from untrusted URL fragments by default
  • Require explicit user confirmation before switching or replacing an active session
  • Validate the source, structure, and intended purpose of session-transition data
  • Use narrowly scoped, single-use, and time-limited session handoff tokens where such flows are necessary
  • Preserve or back up encryption keys before destructive session or storage operations
  • Isolate guest-session storage from authenticated-user storage
  • Apply least-privilege access to local stores and minimize destructive cleanup behavior

Mitigation generally focuses on preventing URL-controlled data from silently changing authenticated session state.

Common defensive patterns include:

  • Do not accept guest credentials from untrusted URL fragments by default
  • Require explicit user confirmation before switching or replacing an active session
  • Validate the source, structure, and intended purpose of session-transition data
  • Use narrowly scoped, single-use, and time-limited session handoff tokens where such flows are necessary
  • Preserve or back up encryption keys before destructive session or storage operations
  • Isolate guest-session storage from authenticated-user storage
  • Apply least-privilege access to local stores and minimize destructive cleanup behavior

How teams detect issues like this

Organizations can assess this class of issue through:

  • Static analysis for session changes driven directly by URL parameters
  • Code review checks for authentication, logout, storage-clearing, or account-switching actions triggered without explicit user intent
  • Browser testing with cross-origin links and attacker-controlled fragment values
  • Policy enforcement requiring origin validation and confirmation for sensitive session transitions
  • Automated security testing that verifies authenticated state and local encryption material remain intact when crafted links are opened

Organizations can assess this class of issue through:

  • Static analysis for session changes driven directly by URL parameters
  • Code review checks for authentication, logout, storage-clearing, or account-switching actions triggered without explicit user intent
  • Browser testing with cross-origin links and attacker-controlled fragment values
  • Policy enforcement requiring origin validation and confirmation for sensitive session transitions
  • Automated security testing that verifies authenticated state and local encryption material remain intact when crafted links are opened

Sources

SourceLink
abraxaslabs.techabraxaslabs.tech/research/element-fragment-guest
github.comgithub.com/element-hq/element-web
github.comgithub.com/element-hq/element-web/blob/v1.12.31/apps/web/src/Lifecycle.ts#L188
github.comgithub.com/element-hq/element-web/commit/792453c88a399d570599f5d73b08b40157cd80c0
github.comgithub.com/element-hq/element-web/releases/tag/v1.12.32
github.comgithub.com/element-hq/element-web/security/advisories/GHSA-c88w-7h6p-27xr
vulncheck.comvulncheck.com/advisories/element-web-and-element-desktop-before-1.12.32-forced-logout-via-guest-credential-url-parameters

Frequently asked

questions

Yes, an attacker may be able to deliver a crafted link remotely, but exploitation generally requires a logged-in user to open that link in an affected Element client.

No. The described attack relies on influencing the victim's client through URL fragment parameters rather than obtaining the victim's account password or access token.

Do not silently accept guest credentials from untrusted URLs. Require explicit confirmation, validate session-transition data, and prevent guest flows from replacing authenticated sessions or destroying local stores without a deliberate user action.

Treat URL parameters as untrusted input, review all state-changing browser and desktop actions for CSRF exposure, isolate guest and authenticated storage, and ensure encryption keys are backed up before potentially destructive session operations.

Yes, an attacker may be able to deliver a crafted link remotely, but exploitation generally requires a logged-in user to open that link in an affected Element client.

No. The described attack relies on influencing the victim's client through URL fragment parameters rather than obtaining the victim's account password or access token.

Do not silently accept guest credentials from untrusted URLs. Require explicit confirmation, validate session-transition data, and prevent guest flows from replacing authenticated sessions or destroying local stores without a deliberate user action.

Treat URL parameters as untrusted input, review all state-changing browser and desktop actions for CSRF exposure, isolate guest and authenticated storage, and ensure encryption keys are backed up before potentially destructive session operations.

Find out what's already
exploitable in your codebase.