#22886Make menu titles in the FE htmlspecialchared by default
Description
1. to prevent XSS (by editors who can create pages)
2. to make the FE valid
(issue imported from #M14732)
Reviews 2
Linked, but not in Forger: Change 59333
History 1921
-
Helmut Hummel commented 01/14/11, 20:47
-
Oliver Klee commented and changed TYPO3 Version
4.44.6 10/15/11, 15:57Steps to reproduce (on current master):
- Create a site that uses a normal TMENU.
- Create a page with the following title:
ROFL <script>alert(1);</script> - View the page in the FE
Expected results:
no pop-ups, the script code is visible in the menueactual results:
2x the “1” popup -
Steffen Gebert changed target version TYPO3 Version
4.64.7 10/17/11, 20:06 -
Steffen Ritter changed target version 04/23/12, 22:39
-
Steffen Ritter commented and changed target version TYPO3 Version
4.76.0 05/15/12, 11:31This is a change of behaviour which will lead to regressions in production sites, therefore I would like to only see that one in master
-
Helmut Hummel commented and changed project id 07/29/12, 13:17
Moving this to the public issue tracker for discussion.
No need to handle that in secret
-
Mathias Schreiber changed target version Is Regression 0 01/12/15, 11:08
-
Benni Mack changed target version 06/15/15, 18:12
-
Gerrit Code Review changed status
NewUnder Review 06/15/15, 18:34 Patch set 1 for branch *master* of project *Packages/TYPO3.CMS* has been pushed to the review server. It is available at http://review.typo3.org/40260 -
Benni Mack changed status
Under ReviewNew 06/30/15, 00:08 -
Susanne Moog changed target version 08/05/15, 10:31
-
Benni Mack changed assigned to Benni Mack target version 09/24/15, 20:06
-
Riccardo De Contardi changed category 12/06/15, 11:31
-
Benni Mack changed target version 03/30/17, 14:40
-
Susanne Moog changed category 10/27/17, 13:13
-
Riccardo De Contardi commented 06/28/18, 23:03
just a note: this issue affects only menus built with HMENU/TMENU; if the menu is built via menuProcessor, it is not present.
-
Georg Ringer changed assigned to Georg Ringer 01/04/19, 20:19
-
Gerrit Code Review pushed patch set 1 for master to change 59333 status
NewUnder Review 01/04/19, 20:52 -
Susanne Moog commented and changed status
Under ReviewAccepted 03/01/19, 18:32Review not found.
-
Benni Mack commented and changed status
AcceptedNeeds Feedback removed the assignee 06/21/24, 09:58Hey,
I don’t know about this one: Right now, this happens only with TMENU in pure TypoScript – people nowadays use Fluid (with the data processor), so it’s rather a low impact compared to 14 years ago, when the ticket was opened. Thus, justifying the breaking change (for v14 only) should also be checked with the security team.
My 2 cents: I personally use TypoScript HMENU for a Headless and adding HSC there by default isn’t the right spot IMHO, otherwise people would need to disable it. For that, I’d rather keep it as is for the time being.
-
Torben Hansen commented and changed status
Needs FeedbackClosed 06/24/24, 06:44The TYPO3 security team discussed this topic and came to the conclusion, that the behavior should not be changed, since it is highly breaking and integrators can use
stdWrap.htmlSpecialChars = 1to prevent XSS in TypoScript generated menus. Rather than changing the code in this area, the documentation about this behavior for TMENU should be updated and possibilities to mitigate XSS in TMENU should be described. This ticket will therefore be closed now.I added a note on my todo list to update the TMENU documentation and to outline, that user input in TMENU is not escaped by default. Additionally, I will update all doc examples for TMENU to include
stdWrap.htmlSpecialChars = 1.
Do you mean TypoScript like foo = TMENU … or something in css_styled_content.
AFAIK everything that outputs editors content is hsc’d in css_styled_content