Skip to main content

Logto EUVDEUVD-2026-43009

| CVE-2026-54714 MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2026-07-10 security-advisories@github.com
6.1
CVSS 3.1 · Vendor: github
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Identify Logto tenant with SAML app enabled
  2. Delivery
    Enumerate valid SAML application ID
  3. Exploit
    Craft malicious RelayState payload in /api/saml/:id/authn URL
  4. Install
    Deliver link to victim via phishing
  5. C2
    Victim completes SAML login flow
  6. Execute
    Injected script executes on Logto tenant origin
  7. Impact
    Harvest session tokens or OIDC credentials

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

The SAML application feature must be configured and active in the Logto instance - this is not a default-on feature for all Logto deployments and requires deliberate administrative setup of a SAML application. The attacker must know or enumerate a valid SAML application identifier (:id in the /api/saml/:id/authn route). The victim must follow the attacker-crafted link and complete the SAML authentication flow (UI:R from CVSS vector confirms mandatory user interaction). The attacker requires no authentication credentials of their own (PR:N from CVSS). Exploitation is limited to Logto instances with externally accessible SAML endpoints; instances deployed with /api/saml routes behind internal-only network access significantly reduce the realistic attack surface.

Impact

The CVSS 3.1 base score of 6.1 (AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N) accurately reflects a network-accessible, low-complexity reflected XSS with a scope change. The scope change (S:C) is the most significant signal: execution on the Logto identity provider origin is materially more dangerous than XSS on a typical application, because it can expose session tokens, OIDC refresh tokens, or administrative credentials for the entire tenant. No EPSS score was provided in the intelligence data, so exploitation probability cannot be quantified. The vulnerability is not listed in CISA KEV, and no standalone public exploit code is identified; the GitHub fix commit (209fa0a5) and PR #9008 are publicly visible and could be reverse-engineered to craft payloads, moderately lowering the exploitation barrier. The mandatory user-interaction step (UI:R - victim must complete a SAML login flow) limits opportunistic mass exploitation, but targeted attacks against specific Logto tenants using phishing or malicious links are realistic. Overall: medium-priority, elevated by the identity-provider context; should be patched promptly rather than deferred.

Exploit ScenarioDerived

An attacker identifies a publicly accessible Logto tenant with SAML federation enabled and discovers (or enumerates) a valid SAML application ID. They construct a malicious URL to /api/saml/:id/authn with a crafted RelayState parameter containing an HTML-attribute-breaking payload (e.g., closing an attribute and injecting an onerror handler), then deliver this link to a target user via phishing email. When the victim clicks the link and completes their normal SAML login, the Logto-generated auto-submit form renders the unescaped RelayState, executing the injected script in the victim's browser under the Logto tenant origin, potentially harvesting session cookies or OIDC tokens.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jul 10, 2026

Reflected XSS in Logto's SAML application flow allows unauthenticated remote attackers to inject and execute arbitrary JavaScript on the Logto tenant origin by supplying a crafted RelayState parameter. Versions prior to 1.41.0 of @logto/core reflect the SAML RelayState, SAMLResponse, and actionUrl directly into an auto-submit HTML form without HTML-attribute escaping, meaning a victim who follows a crafted SAML authentication link and completes the login sequence will execute attacker-controlled script within the identity provider's origin context. No active exploitation has been confirmed (not in CISA KEV) and no public exploit code has been identified at time of analysis, though a GitHub security advisory and fix commit are publicly available.

RemediationAI

Upgrade Logto to version 1.41.0 or later, which contains the HTML-attribute escaping fix applied in commit 209fa0a5cbe8522f9cf31873239dc6424099bb5e (PR #9008). The official release is available at https://github.com/logto-io/logto/releases/tag/v1.41.0 and the security advisory is at https://github.com/logto-io/logto/security/advisories/GHSA-cpm5-w86q-w85f. If immediate upgrade is not feasible, a compensating control is to disable SAML application functionality entirely within the Logto admin console, eliminating the vulnerable code path; this trade-off is that any SAML-federated service providers relying on Logto as an IdP will lose authentication capability. Network-layer controls (blocking external access to /api/saml/:id/authn) can reduce attack surface if Logto is only used for internal SAML federation, but will not protect against threats originating from the internal network. Content Security Policy headers, if configurable via a reverse proxy in front of Logto, can limit the impact of injected scripts but are not a substitute for the code fix.

Affected VersionsENISA

logto < 1.41.0

Affected Packages

euvd logto fix: 1.41.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

Logto is an open-source, self-hosted authentication and authorization infrastructure implementing OIDC and SAML protocols, targeting SaaS and AI application developers. The flaw resides in packages/core/src/saml-application/SamlApplication/utils.ts, where the SAML RelayState - an opaque passthrough string defined by the SAML protocol to allow service providers to maintain state across the authentication redirect loop - along with SAMLResponse and actionUrl, are interpolated into an auto-submit HTML form template without HTML-attribute escaping. CWE-79 (Improper Neutralization of Input During Web Page Generation) is the root cause class: unsanitized user-supplied data reaches an HTML rendering context, enabling injection of event handlers or script tags. Because the form is served from the Logto tenant origin, successful injection yields same-origin script execution against the identity provider itself, which may hold session cookies, OIDC tokens, and administrative interfaces.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (github) PRIMARY 6.1 MEDIUM
AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
vuln.today AI 6.1 MEDIUM

Network-delivered reflected XSS, no attacker privileges needed, victim must complete login (UI:R), scope changes to Logto origin; no availability impact.

3.1 AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N
4.0 AV:N/AC:L/AT:N/PR:N/UI:A/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (github).

CVSS VectorVendor: github

Attack Vector
Network
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Changed
Confidentiality
Low
Integrity
Low
Availability
None

Lifecycle Timeline

1
Patch available
Jul 10, 2026 - 21:02 EUVD

DescriptionCVE.org

Logto is the modern, open-source auth infrastructure for SaaS and AI apps. Prior to 1.41.0, @logto/core reflected the SAML RelayState, SAMLResponse, and actionUrl into a Logto-origin auto-submit HTML form in packages/core/src/saml-application/SamlApplication/utils.ts without HTML-attribute escaping. A SAML application flow with a crafted RelayState from GET or POST /api/saml/:id/authn could inject script that runs on the Logto tenant origin after the user completes login. This issue is fixed in version 1.41.0.

Threat Intelligence Overview

EPSS Score
0.3%
Top 83% exploitable
Prevalence
Low
open-source auth platform, growing but niche adoption among SaaS/AI developers
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

30
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +30
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy