Summary
Multiple system messages are inserted into the CommandPaletteFooter as raw HTML, allowing anybody who can edit those messages to insert arbitrary HTML into the DOM.
Details
The messages are retrieved using the plain() output mode:
|
const tips = [ |
|
mw.message( 'citizen-command-palette-tip-commands' ).plain(), |
|
mw.message( 'citizen-command-palette-tip-users' ).plain(), |
|
mw.message( 'citizen-command-palette-tip-namespace' ).plain(), |
|
mw.message( 'citizen-command-palette-tip-templates' ).plain() |
|
]; |
currentTip is set to one of these messages:
|
const currentTip = computed( () => tips[ currentTipIndex.value ] ); |
currentTip is inserted as raw HTML (
vue/no-v-html should
not be ignored here):
|
<!-- eslint-disable-next-line vue/no-v-html --> |
|
<div class="citizen-command-palette__footer-note" v-html="currentTip"></div> |
PoC
- Edit
citizen-command-palette-tip-commands, citizen-command-palette-tip-users, citizen-command-palette-tip-namespace and citizen-command-palette-tip-templates to <img src="" onerror="alert(1)"> (script tags don't work here due to the way the HTML is inserted)
- Open the command palette

Impact
This impacts wikis where a group has the editinterface but not the editsitejs user right.
Summary
Multiple system messages are inserted into the CommandPaletteFooter as raw HTML, allowing anybody who can edit those messages to insert arbitrary HTML into the DOM.
Details
The messages are retrieved using the
plain()output mode:mediawiki-skins-Citizen/resources/skins.citizen.commandPalette/components/CommandPaletteFooter.vue
Lines 61 to 66 in 072e436
currentTipis set to one of these messages:mediawiki-skins-Citizen/resources/skins.citizen.commandPalette/components/CommandPaletteFooter.vue
Line 69 in 072e436
currentTipis inserted as raw HTML (vue/no-v-htmlshould not be ignored here):mediawiki-skins-Citizen/resources/skins.citizen.commandPalette/components/CommandPaletteFooter.vue
Lines 3 to 4 in 072e436
PoC
citizen-command-palette-tip-commands,citizen-command-palette-tip-users,citizen-command-palette-tip-namespaceandcitizen-command-palette-tip-templatesto<img src="" onerror="alert(1)">(script tags don't work here due to the way the HTML is inserted)Impact
This impacts wikis where a group has the
editinterfacebut not theeditsitejsuser right.