Skip to main content
Mallory
CriticalPublic exploitVulnerability

CVE-2025-5352: Stored XSS in lunary Analytics custom script injection

Published Aug 23, 2025 · Updated 2 months ago
Trending this weekNot trendingOutside this week’s top 100
Mention activity · 30 daysNo mention activity in the last 30 days.
CVSS9.6Critical · v3.1
EPSS0.58%48th percentile
CISA KEVNoNot listed
In the wildNonePublic exploit, no exploitation reported
Vendor
Lunary
IdentifiersCVE-2025-5352CWE-79 · Improper Neutralization of Input…

CVE-2025-5352 is a critical stored cross-site scripting vulnerability in the Analytics component of lunary-ai/lunary affecting versions up to 1.9.23. The issue arises because the NEXT_PUBLIC_CUSTOM_SCRIPT environment variable is injected directly into the DOM via dangerouslySetInnerHTML without sanitization or validation. If an attacker can control that environment variable during deployment or through compromise of the server or deployment pipeline, they can supply arbitrary HTML/JavaScript that will be rendered and executed in users' browsers. Because the injected payload is stored in application configuration and served to all visitors, this is effectively a persistent XSS condition affecting all users of the instance until the malicious value is removed. The issue is reported fixed in version 1.9.25.

Do you run this?See affected versions in your environment and whether adversaries are exploiting this vulnerability against assets like yours.
Check your exposure
Analyst brief

Impact, mitigation & remediation

What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Successful exploitation enables arbitrary JavaScript execution in the browser context of users visiting the affected application. Depending on application behavior and browser context, this can enable session theft, account takeover, unauthorized actions on behalf of victims, exfiltration of sensitive application data accessible to the client, delivery of further malicious content, and persistent compromise of user interactions across the affected instance. Because the payload is served to all users, the blast radius can include the full user population of the deployment.

Mitigation

If you can’t patch tonight, do this now.

If immediate upgrade is not possible, disable or clear the NEXT_PUBLIC_CUSTOM_SCRIPT environment variable and redeploy. Restrict who can modify deployment-time environment variables and harden CI/CD, hosting, and server administration paths to prevent configuration tampering. Apply a restrictive Content Security Policy where feasible to reduce script execution impact, although CSP may not fully mitigate intentionally injected inline script depending on policy. Monitor for unexpected changes to environment variables and inspect rendered analytics/custom script content for unauthorized payloads.

Remediation

Patch, then assume compromise.

Upgrade lunary-ai/lunary to version 1.9.25 or later, where the issue is fixed. In addition, remove any malicious or untrusted value from the NEXT_PUBLIC_CUSTOM_SCRIPT environment variable, review deployment and CI/CD systems for unauthorized changes, and audit server-side configuration management for compromise. The vulnerable pattern of rendering untrusted content with dangerouslySetInnerHTML should be eliminated or protected with strict sanitization and allowlisting before any HTML is inserted into the DOM.

Public exploits

Exploits

No validated public exploits yet. Hidden: 1 rejected by Mallory's analysis as not a working exploit.

View more in app →
Every candidate exploit was rejected by Mallory's analysis.
Exposure surface

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
LunaryLunaryapplication
FAQ

Frequently asked questions

Is CVE-2025-5352 exploited in the wild?
As of Sep 25, 2026, Mallory has no reports of CVE-2025-5352 being exploited in the wild. It is not listed in CISA KEV.
Is there a public exploit for CVE-2025-5352?
Yes. As of Sep 25, 2026, Mallory has reports of a public exploit for CVE-2025-5352.
Is there a patch for CVE-2025-5352?
Upgrade lunary-ai/lunary to version 1.9.25 or later, where the issue is fixed. In addition, remove any malicious or untrusted value from the NEXT_PUBLIC_CUSTOM_SCRIPT environment variable, review deployment and CI/CD systems for unauthorized changes, and audit server-side configuration management for compromise.
What products are affected by CVE-2025-5352?
Lunary.
How severe is CVE-2025-5352?
CVE-2025-5352 has a CVSS v3.1 score of 9.6 (Critical) and an EPSS score of 0.58% (48th percentile) as of Sep 25, 2026.
Activity feed

Recent activity

4 sources tracked across advisories and community write-ups. News coverage will land here when it surfaces.

View more in app →

No news coverage yet. Advisories and community discussion only.

Do you run this?See affected versions in your environment and whether adversaries are exploiting this vulnerability against assets like yours.
Check your exposure
Mallory platform

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, and which detections to deploy tonight.
Exposure mappingQuery your assets running an affected version, and investigate the blast radius.
Threat actor evidenceEvery report linking this CVE to a named adversary.
Associated malwareMalware families linked to this CVE, with evidence and IOCs.
Detection signaturesYARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.
Vendor-by-vendor mappingCross-references every affected SKU, including bundled OEM variants.
Social activity4Community discussion across Reddit, Mastodon, and other social sources.