Page MenuHomePhabricator

CVE-2025-61650: UserInfoCard is vulnerable to message key stored XSS
Closed, ResolvedPublicSecurity

Description

The CheckUser-UserInfoCard feature is vulnerable to message key XSS through several messages

Problem messages

Message name(s)Override using stored XSSResulting alert showing that JavaScript was run
All group-* messages
image.png (232×960 px, 19 KB)
image.png (1×1 px, 148 KB)
checkuser-userinfocard-groups
image.png (241×971 px, 22 KB)
image.png (1×1 px, 157 KB)
All global group messages
image.png (226×968 px, 25 KB)
image.png (1×1 px, 155 KB)
checkuser-userinfocard-global-groups
image.png (251×966 px, 24 KB)
image.png (1×1 px, 161 KB)

Acceptance criteria

Details

Risk Rating
Low
Author Affiliation
WMF Product
Related Changes in Gerrit:

Event Timeline

This wasn't findable using the normal x-xss language, because the script tags were not loaded if they are added to the DOM after the fact (AFAICS). I had to use <img src="" onerror="alert(1)"> to get the javascript to fire.

Perhaps we can consider updating the X-XSS language to use something like <img src="" onerror="alert('<message key>')"> instead, so that it's easier to detect message key XSS when the XSS occurs after page load.

+2. Works locally for me.

Given it's a US Holiday, the Security-Team might not be able to deploy this. Therefore, I'm going to see if I can deploy this myself.

The proposed patch does not apply to wmf.16. It does apply to the master branch.

Applied a version of the patch to wmf.16 that applies (it seemed just doing a three way merge fixed the issue).

Applied the original version of the patch to wmf.17.

Given this issue is minor (in terms of comparing to other possible security problems), I think we can skip QA on this.

Filed {T403407} to update the x-xss language to support detection of this type of i18n XSS

SecurityPatchBot triaged this task as Unbreak Now! priority.Sep 10 2025, 11:55 PM
Patch is blocking upcoming release

Patch 04-T403289.patch is currently failing to apply for the most recent code in the mainline branch of extensions/CheckUser. This is blocking MediaWiki release 1.45.0-wmf.19(T396380)


If the patch needs to be rebased

A new version of the patch can be placed at the right location in the deployment server with the following Scap command:

REVISED_PATCH=<path_to_revised_patch>
scap update-patch --message-body 'Rebase to solve merge conflicts' /srv/patches/next/extensions/CheckUser/04-T403289.patch "$REVISED_PATCH"

If the patch has been made public

The patch can be dropped in the deployment server with the following Scap command:

scap remove-patch --message-body 'Dropping patch already made public' /srv/patches/next/extensions/CheckUser/04-T403289.patch

I've updated the patch (however, I don't have deploy rights, so it's not placed on the server):

mszwarc lowered the priority of this task from Unbreak Now! to Medium.Sep 11 2025, 9:01 AM

I'll update the patch on the deployment server, otherwise the bot will re-apply UBN and the parent task shortly

Reedy renamed this task from UserInfoCard is vulnerable to message key stored XSS to CVE-2025-61650: UserInfoCard is vulnerable to message key stored XSS.Sep 29 2025, 1:36 PM

Unless I'm mistaken.. Both of these are only in master, not in a release branch rECHU1da1d9e72bb0: UserInfoCard: Display active global groups and rECHU280ff12ac104: UserInfoCard: Display user groups seemingly added them...

Change #1193256 had a related patch set uploaded (by Reedy; author: STran):

[mediawiki/extensions/CheckUser@master] SECURITY: Escape XSS vector in UserInfoCard

https://gerrit.wikimedia.org/r/1193256

Change #1193256 merged by jenkins-bot:

[mediawiki/extensions/CheckUser@master] SECURITY: Escape XSS vector in UserInfoCard

https://gerrit.wikimedia.org/r/1193256

Catrope moved this task from In Progress to Our Part Is Done on the Security-Team board.

Should this not be made public now?

Should this not be made public now?

Yep, I can do that now. I think @Catrope's actions above were from our attempt to tidy up the Security-Team workboard yesterday, which didn't necessarily involve making private tasks public.

sbassett changed Author Affiliation from N/A to WMF Product.Jan 27 2026, 3:13 PM
sbassett removed a project: Patch-For-Review.
sbassett changed the visibility from "Custom Policy" to "Public (No Login Required)".
sbassett changed the edit policy from "Custom Policy" to "All Users".
sbassett changed Risk Rating from N/A to Low.