Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2026-68921— DiceBear: SVG injection via the unescaped rotate option in @dicebear/core (and fontSize/fontWeight in @dicebear/initials)

Quick assessment

Affected
dicebear dicebear
Exploitation
No confirmed in-the-wild exploitation; assess based on exposure
Recommended action
Check the vendor advisory and references for a fixed version. If immediate upgrade is impossible, restrict exposure and increase monitoring.

DiceBear 是一款面向设计师和开发者的头像生成库。在 9.4.3 版本之前, 中的 函数(位于 )会将 选项插值到 SVG 的 属性中,但未进行 XML 转义;同时, (位于 )也直接输出 和 而未进行转义。尽管 TypeScript 类型定义中这些参数为数值类型,但运行时调用者仍可能传入字符串值,从而突破属性边界,注入任意 SVG 标记。当生成的头像以内联方式插入页面,或作为 类型直接打开时,可能导致脚本在页面上下文中执行。然而,要利用此漏洞,应用程序必须将不受信任的值传入这些通常由开发者控制的选项。该问题

CVSS 4.7 · Medium EPSS 0.22% · P13

Possible ATT&CK Techniques 1 AI

T1133 · External Remote Services

Affected Version Matrix 1

VendorProduct Version RangeStatus
dicebear dicebear < 9.4.3 affected
Get alerts for future matching vulnerabilities Log in to subscribe

I. Basic Information for CVE-2026-68921

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
DiceBear: SVG injection via the unescaped rotate option in @dicebear/core (and fontSize/fontWeight in @dicebear/initials)
Source: CVE Program / CVE List V5
Vulnerability Description
DiceBear is an avatar library for designers and developers. Prior to 9.4.3, @dicebear/core interpolates the rotate option into an SVG transform attribute without XML escaping in addRotate in packages/@dicebear/core/src/utils/svg.ts, while @dicebear/initials similarly emits fontSize and fontWeight without escaping in packages/@dicebear/initials/src/index.ts. Runtime callers can pass strings despite the numeric TypeScript types, break out of the attributes, and inject arbitrary SVG markup. Script can execute in the page origin when the generated avatar is inserted inline or served as image/svg+xml and opened directly, although exploitation requires an application to pass untrusted values into these normally developer-controlled options. This issue is fixed in @dicebear/core and @dicebear/initials version 9.4.3.
Source: CVE Program / CVE List V5
CVSS Information
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:L/I:L/A:N
Source: CVE Program / CVE List V5
Vulnerability Type
在Web页面生成时对输入的转义处理不恰当(跨站脚本)
Source: CVE Program / CVE List V5

Affected Products

Vendor Product Affected Versions CPE Subscribe
dicebear dicebear < 9.4.3 -

II. Public POCs for CVE-2026-68921

# POC Description Source Link Shenlong Link
AI-Generated POC Premium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2026-68921

登录查看更多情报信息。

Patches & Fixes for CVE-2026-68921 (1)

Vendor Advisories for CVE-2026-68921 (1)

Vendor Pages for CVE-2026-68921 (1)

IV. Related Vulnerabilities

V. Comments for CVE-2026-68921

No comments yet


Leave a comment