Dixit Wikipedia, "MoinMoin is a wiki engine implemented in Python, initially based on the PikiPiki wiki engine. The MoinMoin code is licensed under the GNU General Public License v2, or (at the user's option) any later version (except some 3rd party modules that are licensed under other Free Software licenses compatible with the GPL). A number of organizations use MoinMoin to run public wikis, including notable free software projects Ubuntu, Apache, Debian, FreeBSD, and others."


By default, the 'allow_xslt' configuration option is set to False. If this option is set to True, then "read/write/overwrite arbitrary path/file as the moin process uid/gidarbitrary" is possible. These bugs are triggered by inserting then displaying wiki pages containing XSLT code.

This behavior was documented between versions 1.9.3 (June 2010) and 1.9.4 (should be released soon) : MoinMoin security page, commit.

File disclosure

Using a XML External Entity attack, it is possible to read text files (PoC).

Note : I was unable to abuse the doc-as-string() extension function because of the MoinMoin URL Resolver. However, I didn't spend much time on it, given that a XEE vulnerability was already found.

File creation

As described on the 4Suite page, the <exsl:document> extension element allows file creation (PoC).

Self-referencing PoC

The two attached PoC are used as both XML data and XSLT code (Homoiconicity !). If you upload them with an other name, you must modify accordingly <?xml-stylesheet href="XXXX" type="text/xml"?>.

Created by Nicolas Gregoire on 2012/01/24 20:06


Welcome on the XSLT Hacking Encyclopedia !

You may be interested by the Engines and Applications pages.

Link to the blog
Twitter: @Agarri_FR

Tag Cloud

Unknown macro: tagcloud.
Content by Nicolas Grégoire / Agarri
Blog - Follow me @Agarri_FR