• Helmut Hummel's avatar
    [BUGFIX] Decode tag attributes during HTML parsing · 917c7d8b
    Helmut Hummel authored
    When parsing HTML in parsefunc, we need to make sure
    that the attributes that are extracted for further processing
    are properly HTML decoded, as per definition they are encoded in
    the HTML being parsed.
    
    At the same time we revert a decode that was applied in ExternalUrlLinkBuilder,
    as this is the wrong place to handle HTML decoding, as the link builder
    is as well called with data from other contexts (TypoScript, data from link fields)
    that must not have the URL HTML encoded.
    
    This fix is required to allow email links to add subject and body arguments like:
    test@foo.test?subject=foo%20bar&body=baz
    
    and not have the ampersand in the url double encoded when generating links
    from RTE content.
    
    Additionally we need to properly encode the masked value for the JavaScript
    URI, to prevent browsers from url decoding wrong values.
    
    Releases: master, 9.5
    Resolves: #89264
    Related: #81625
    Related: #80985
    Change-Id: I3be2478df83cffc0dfe6af918eb224b4ee480b10
    Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62227
    
    
    Tested-by: default avatarBenni Mack <benni@typo3.org>
    Tested-by: default avatarTYPO3com <noreply@typo3.com>
    Reviewed-by: default avatarBenni Mack <benni@typo3.org>
    917c7d8b