Home/Research/Post

GHSA-crj3-q72p-ggqm: @waline/client vulnerable to stored XSS through unsanitized comment edit previews

  • Severity: CRITICAL
  • CVE: CVE-2026-64670
  • Ecosystems: npm
  • Packages: @waline/client

### Summary

`@waline/client` renders the comment editor’s live preview with `marked` and no sanitizer (`utils/markdown.ts`), and the preview is injected with `v-html`.

When a comment is edited, the editor is seeded with the comment’s raw, un-sanitized body (`orig`).

Only administrators and the comment owner can edit. So an administrator who clicks Edit on an attacker’s comment renders that attacker’s raw HTML in their own session: an unauthenticated commenter achieves privilege-escalation stored XSS against a moderator with a single Edit click.

### Details

`packages/client/src/utils/markdown.ts:18-37` renders markdown with `marked` and returns the raw HTML with no sanitization (the client bundles no DOMPurify):

“`ts
return marked.parse(parseEmoji(content, emojiMap)) as string;
“`

`packages/client/src/components/CommentBox.vue`:

“`ts
onMounted(() => {
if (props.edit?.objectId) editor.value = props.edit.orig; // :509 raw comment body
watchImmediate(() => editor.value, (value) => {
previewText.value = parseMarkdown(value, { … }); // :519 runs immediately on mount
});
});
“`

“`html

“`

`watchImmediate` runs the callback synchronously at mount, so `previewText` is populated with the unsanitized render as soon as the box mounts in edit mode.

`v-show` (not `v-if`) means the `v-html` node is present in the DOM (display:none), so an “ fires without the moderator ever opening the preview tab.

The tainted value is the attacker’s raw comment. `packages/server/src…

Source: GitHub Security Advisories · 2026-11-25