svelte-meta-tags is vulnerable to Cross-Site Scripting (XSS)
59
Medium Risk
The JsonLd component renders structured data by serializing the schema with JSON.stringify and injecting the result into an inline <script type="application/ld+json"> block using {@html}. The < character in the serialized output is not escaped, so a schema value that contains a </script> sequence closes the JSON-LD script element and lets arbitrary markup be injected into the rendered page. When schema values include untrusted or user-controlled data, this leads to cross-site scripting in the server-rendered HTML. The fix escapes < as the JSON escape sequence \u003c before the serialized JSON-LD is written into the script tag.
You are affected if you are using a version that falls within the vulnerable range and you render JSON-LD schema values that contain untrusted or user-controlled data.
svelte-meta-tags is vulnerable to Cross-Site Scripting (XSS) in versions 1.1.0 - 5.0.1.
Upgrade the svelte-meta-tags library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant