-
Notifications
You must be signed in to change notification settings - Fork 673
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[SECURITY] Avoid XSS by correctly encoding typolink results
In order to avoid XSS through typolink, anchor text is encoded correctly to be used in a HTML context. Fallback link texts of links to pages are encoded per default in case lib.parseFunc has not been configured. Resolves: #88635 Releases: master, 9.5, 8.7 Security-Commit: 57c5eeb93e6df4b1958bcafcd85ada6c7e355d41 Security-Bulletin: TYPO3-CORE-SA-2019-022 Change-Id: I9a415d6b2ed494dac7f4747e25460d95e1f27284 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/62704 Tested-by: Oliver Hader <oliver.hader@typo3.org> Reviewed-by: Oliver Hader <oliver.hader@typo3.org>
- Loading branch information
Showing
8 changed files
with
509 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
40 changes: 40 additions & 0 deletions
40
typo3/sysext/frontend/Tests/Functional/SiteHandling/Fixtures/TypoLinkScenario.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
__variables: | ||
- &pageStandard 0 | ||
- &pageShortcut 4 | ||
|
||
entitySettings: | ||
'*': | ||
nodeColumnName: 'pid' | ||
columnNames: {id: 'uid', language: 'sys_language_uid'} | ||
defaultValues: {pid: 0} | ||
page: | ||
isNode: true | ||
tableName: 'pages' | ||
parentColumnName: 'pid' | ||
languageColumnNames: ['l10n_parent', 'l10n_source'] | ||
columnNames: {type: 'doktype', root: 'is_siteroot'} | ||
defaultValues: {hidden: 0, doktype: *pageStandard} | ||
valueInstructions: | ||
shortcut: | ||
first: {shortcut: 0, shortcut_mode: 1} | ||
content: | ||
tableName: 'tt_content' | ||
languageColumnNames: ['l18n_parent', 'l10n_source'] | ||
columnNames: {title: 'header', type: 'CType'} | ||
defaultValues: {hidden: 0, CType: 'text'} | ||
|
||
entities: | ||
page: | ||
- self: {id: 1000, title: 'ACME Inc', type: *pageShortcut, shortcut: 'first', root: true, slug: '/'} | ||
children: | ||
- self: {id: 1100, title: 'EN: Welcome', slug: '/welcome', subtitle: 'hello-and-welcome'} | ||
entities: | ||
content: | ||
- self: {title: 'EN: Content Element #1'} | ||
- self: {title: 'EN: Content Element #2'} | ||
- self: {id: 1200, title: 'EN: Features', slug: '/features'} | ||
- self: {id: 9911, title: '<good>', slug: '/test/good'} | ||
- self: {id: 9912, title: '<good a="a/" b="thing(1)">', slug: '/test/good-a-b-spaced'} | ||
- self: {id: 9913, title: '<good%20a="a/"%20b="thing(1)">', slug: '/test/good-a-b-enc-a'} | ||
- self: {id: 9914, title: '<good/a="a/"/b="thing(1)">', slug: '/test/good-a-b-enc-b'} | ||
- self: {id: 9921, title: '<bad>', slug: '/test/bad'} |
Oops, something went wrong.