Issue Bug Closed

#109599Potential security issue in EXT:theme_camino backend preview rendering

Oliver Hader 04/16/26, 12:10 updated 04/21/26, 11:30

Description

Credits to Sebastian Michaelsen for finding the flaw described below and reporting it to the TYPO3 security team.
The backend Content-Security-Policy already blocked execution of injected event handlers in practice, but this change
removes the unsafe rendering pattern as a defence-in-depth measure. That’s why this change is handled in public.

—-

> I would like to report a potential security issue in TYPO3, specifically EXT:theme_camino which is shipped with TYPO3 14.x.
>
> Summary:
> theme_camino backend preview templates render editor-controlled content using stripTags(…) and f:format.raw(). Because allowed tags retain attributes, attacker-controlled HTML attributes can survive into backend preview rendering.
>
> Affected area:
> typo3/sysext/theme_camino/Resources/Private/Templates/ContentPreviews/*.fluid.html
>
> Example pattern:
> Text preview sections strip tags but allow tags such as sup/sub/br, then output the result raw.
>
> Impact assessment:
> In my local TYPO3 v14 backend, default backend CSP blocked a simple payload such as:
> Preview sink marker
> So I could confirm unsafe backend HTML injection, but not a working stored XSS under default backend CSP.
>
> Current assessment:
> This appears to be at least a defense-in-depth issue and unsafe rendering pattern in backend context. It may become exploitable if backend CSP is weakened, replaced by custom headers, or if a CSP bypass exists.
>
> Steps to reproduce:
>
> Activate EXT:theme_camino
> Create a camino_testimonial record
> Set bodytext to Preview sink marker
> Open the backend page module and inspect the content preview
> The attribute survives in rendered preview markup, although default CSP blocks execution in my test setup
>
> Please let me know if you need anything else.

Reviews 1

History 79

  1. Gerrit Code Review changed status New Under Review <span data-processor="relativetime" data-value="2026-04-16T14:06:35+00:00" > 04/16/26, 14:06 </span> Patch set 1 for branch *main* of project *Teams/Security/TYPO3v4-Core* has been pushed to the review server. It is available at https://review.typo3.org/c/Teams/Security/TYPO3v4-Core/+/93692

  2. Oliver Hader changed project id category target version Field 12 Sebastian Michaelsen Field 13 2026040810000081 Field 17 14 <span data-processor="relativetime" data-value="2026-04-16T20:35:05+00:00" > 04/16/26, 20:35 </span>

  3. Oliver Hader commented and changed status Under Review Resolved done 0 % 100 % <span data-processor="relativetime" data-value="2026-04-17T11:05:08+00:00" > 04/17/26, 11:05 </span>

    Applied in changeset commit:aa737bfbafc09cfd532d93582e5dcd693d5795a9.