Skip to content

Commit

Permalink
Merge branch '3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
Guite committed Sep 20, 2021
2 parents f0a4841 + bc5a435 commit c5ca20f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG-3.0.md
Expand Up @@ -8,6 +8,7 @@
- Fixes:
- [CoreBundle] More robust autoloader detection.
- [CoreBundle] Add `flex-wrap` class to pagination for responsive behaviour ([bs#23504](https://github.com/twbs/bootstrap/issues/23504)).
- [Blocks] Strip script tags from XSLT block stylesheets.
- [Categories] Sanitize context menu in admin category list.
- [Theme] Fix resolving assets location on Windows if Zikula is installed in a sub directory (#4480).
- [Permissions] Correctly handle non-existing username during permission testing.
Expand Down
7 changes: 7 additions & 0 deletions src/system/BlocksModule/Block/XsltBlock.php
Expand Up @@ -41,6 +41,13 @@ public function display(array $properties): string
} else {
$doc->loadXML($properties['stylecontents']);
}

// remove scripts
$scriptTags = $doc->getElementsByTagName('script');
foreach ($scriptTags as $scriptTag) {
$scriptTag->parentNode->removeChild($scriptTag);
}

$xsl->importStyleSheet($doc);

// load xml source
Expand Down

0 comments on commit c5ca20f

Please sign in to comment.