? Pending

User tests: Successful: Unsuccessful:

avatar SniperSister
SniperSister
18 Feb 2018

Summary of Changes

In earlier versions, the escape method of JViewHtml, HtmlView and BaseLayout was using the ENT_COMPAT flag for escaping, which does not escape single quotes. This leads to potential XSS-issues in some situations and therefore should be changed in 4.0.

This is done with this PR.

Testing Instructions

  1. Add echo $this->escape("'"); to a component template of your choice.
  2. Inspect the generated markup in the browser, see the plaintext output of the single quote
  3. Apply this patch, refresh the page
  4. Inspect markup again, see that the quote is now escaped

Expected result

Single quotes are escaped

Actual result

Single quotes aren't escaped.

Documentation Changes Required

None

avatar SniperSister SniperSister - open - 18 Feb 2018
avatar SniperSister SniperSister - change - 18 Feb 2018
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 18 Feb 2018
Category Libraries
avatar Quy Quy - change - 18 Feb 2018
Title
Switch escape() methods to ENT_QUOTES to also cover single quotes
[4.0] Switch escape() methods to ENT_QUOTES to also cover single quotes
avatar joomla-cms-bot joomla-cms-bot - edited - 18 Feb 2018
avatar wilsonge wilsonge - change - 18 Feb 2018
Status Pending Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2018-02-18 17:22:38
Closed_By wilsonge
Labels Added: ?
avatar wilsonge wilsonge - close - 18 Feb 2018
avatar wilsonge wilsonge - merge - 18 Feb 2018

Add a Comment

Login with GitHub to post a comment