Loofah: SVG `href` attribute bypasses local-reference restriction
Loofah's HTML5 sanitizer restricted only the xlink:href attribute on certain SVG elements to local, same-document references. Browsers also accept a plain href attribute as an alternative to the deprecated xlink:href per the SVG 2 spec, but Loofah did not apply the same restriction to it, allowing those elements to reference arbitrary external documents.
SVG <use> can load and render external SVG content by reference. If the referenced external SVG is same-origin and contains scripts or other dangerous content, it could execute in the context of the sanitized document. <feImage> can load external images, which can be used for tracking. Modern browsers restrict cross-origin <use> fetches, which limits but does not eliminate the risk.
Applications that sanitize user-supplied SVG (directly, or as part of HTML) with Loofah's default allowlist are affected.
Upgrade to Loofah >= 2.25.2.
Found by the maintainer, Mike Dalessio, during a security audit.
왜 이 VPI인가 (설명가능 · 실험적)
VPI 산정 기준
| 영향도 | 47.00 |
| 악용 신호(추가 악용신호 없음) | ×1.00 |
| VPI | 47.00 |
VPI 공식 vpi-v1 기준