No Code Attached Yet bug
avatar conseilgouz
conseilgouz
15 Jul 2026

What happened?

With Joomla 5.4.6, when selecting a version of an article history in the list, intro text and full text, html tags are displayed in its preview.

Version

5.4

Expected result

When selecting a version of an article in its versions list, intro text and full text are displayed with no html code.

Image

Actual result

When selecting a version of an article in its versions list, intro text and full text are displayed with html code.

Image

System Information

Joomla 5.4.6
Laragon 8.6
PHP 8.5.7

Additional Comments

This has been introduced in Joomla 5.4.6 by 8c25616
I did not find any comment for this commit.
This adds $this->escape before all echo commands.
In the case of content history preview, in administrator/compnents/com_contenthistory/tmpl/preview/preview.php, lines 54 and 61 replace the values by htmlspecialchars converted values.
Please note that the commit has been merged in 6.1.2, so we have the same behaviour.

avatar conseilgouz conseilgouz - open - 15 Jul 2026
avatar joomla-cms-bot joomla-cms-bot - change - 15 Jul 2026
Labels Added: No Code Attached Yet bug
avatar joomla-cms-bot joomla-cms-bot - labeled - 15 Jul 2026
avatar conseilgouz conseilgouz - change - 15 Jul 2026
The description was changed
avatar conseilgouz conseilgouz - edited - 15 Jul 2026
avatar conseilgouz conseilgouz - change - 15 Jul 2026
The description was changed
avatar conseilgouz conseilgouz - edited - 15 Jul 2026
avatar conseilgouz conseilgouz - change - 15 Jul 2026
The description was changed
avatar conseilgouz conseilgouz - edited - 15 Jul 2026
avatar conseilgouz conseilgouz - change - 15 Jul 2026
The description was changed
avatar conseilgouz conseilgouz - edited - 15 Jul 2026
avatar richard67
richard67 - comment - 15 Jul 2026

The mentioned commit was a security fix.

@SniperSister So it’s expected behavior, right?

avatar SniperSister
SniperSister - comment - 15 Jul 2026

Indeed, that’s expected behavior

avatar brianteeman
brianteeman - comment - 15 Jul 2026

instead of a pure escape can we not use htmlenties then we are still secure but dont lose functionality

avatar richard67
richard67 - comment - 15 Jul 2026
avatar SniperSister
SniperSister - comment - 16 Jul 2026

The underlying issue is:

  • the version history output is a generic one; it has an attribute name ("title"), an old and a new value ; everything is handled the same way
  • the actual component using the version history knows the context of these attributes and therefore can decide if a raw output (allowing HTML) is safe to use or if escaping is required
  • that different handling is the key vector to exploit the vulnerabiliy: a field, that's escaped and therefore safe to use in a component becomes a stored XSS in content history
avatar richard67 richard67 - change - 20 Jul 2026
The description was changed
Status New Expected Behaviour
Closed_Date 0000-00-00 00:00:00 2026-07-20 18:08:41
Closed_By richard67
avatar richard67 richard67 - close - 20 Jul 2026
avatar richard67
richard67 - comment - 20 Jul 2026

Closing as expected behaviour


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/48109.

avatar richard67 richard67 - edited - 20 Jul 2026
avatar richard67
richard67 - comment - 20 Jul 2026

Closing as expected behaviour


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/48109.

avatar conseilgouz
conseilgouz - comment - 21 Jul 2026

The documentation has to be updated : https://guide.joomla.org/user-manual/articles/articles-article-versions
Just to show that users won't be able to understand introtext and full text anymore.

avatar conseilgouz
conseilgouz - comment - 21 Jul 2026

For information, compare versions gives the same kind of result :

Image
avatar conseilgouz
conseilgouz - comment - 21 Jul 2026

For information, compare versions gives the same kind of result :

Image

Is it really what you expected ?

Add a Comment

Login with GitHub to post a comment