CVE-2026-31876: Notesnook has Stored XSS via unsanitized Twitter/X embed URL in editor (`tweetToEmbed`)
Notesnook is a note-taking app focused on user privacy & ease of use. Prior to 3.3.9, a Stored Cross-Site Scripting (XSS) vulnerability existed in Notesnook's editor embed component when rendering Twitter/X embed URLs. The tweetToEmbed() function in component.tsx interpolated the user-supplied URL directly into an HTML string without escaping, which was then assigned to the srcdoc attribute of an <iframe>. This vulnerability is fixed in 3.3.9.
Affected Software
Remediation
Event History
Frequently Asked Questions
What is the severity of CVE-2026-31876?
CVE-2026-31876 is classified as a high severity vulnerability due to the potential for stored cross-site scripting attacks.
How do I fix CVE-2026-31876?
To fix CVE-2026-31876, update your Notesnook application to version 3.3.9 or later, where the vulnerability has been patched.
What is the impact of CVE-2026-31876?
CVE-2026-31876 can allow attackers to execute arbitrary scripts in the context of a user's session, compromising user data and privacy.
Who is affected by CVE-2026-31876?
Users running any version of Notesnook prior to 3.3.9 are affected by CVE-2026-31876.
What is the nature of CVE-2026-31876?
CVE-2026-31876 is a Stored XSS vulnerability that arises from unsanitized URLs in the editor embed component of Notesnook.