Skip to content

Commit c983415

Browse files
bnfohader
authored andcommitted
[SECURITY] Prevent Information Disclosure in record list downloader
Resolves: #107173 Releases: main, 13.4, 12.4 Change-Id: If3e22ce557bd48a4a68edee78e3c87f5fe51f9e4 Security-Bulletin: TYPO3-CORE-SA-2025-023 Security-References: CVE-2025-59019 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/90633 Reviewed-by: Oliver Hader <[email protected]> Tested-by: Oliver Hader <[email protected]>
1 parent 0aedf33 commit c983415

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

Classes/Controller/RecordListDownloadController.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,12 @@ public function handleDownloadRequest(ServerRequestInterface $request): Response
105105
if ($this->table === '') {
106106
throw new \RuntimeException('No table was given for downloading records', 1623941276);
107107
}
108+
109+
$backendUser = $this->getBackendUserAuthentication();
110+
if (!$backendUser->check('tables_select', $this->table)) {
111+
throw new AccessDeniedException('Insufficient permissions for accessing this download', 1756895674);
112+
}
113+
108114
// @todo we might want to throw an exception in case no schema exists for the table
109115
$schema = $this->tcaSchemaFactory->has($this->table) ? $this->tcaSchemaFactory->get($this->table) : null;
110116
$this->format = (string)($parsedBody['format'] ?? '');
@@ -123,7 +129,6 @@ public function handleDownloadRequest(ServerRequestInterface $request): Response
123129
$tsConfig = is_array($tsConfig) ? $tsConfig : null;
124130

125131
// Loading current page record and checking access
126-
$backendUser = $this->getBackendUserAuthentication();
127132
$perms_clause = $backendUser->getPagePermsClause(Permission::PAGE_SHOW);
128133
$pageinfo = BackendUtility::readPageAccess($this->id, $perms_clause);
129134
$searchString = (string)($parsedBody['searchString'] ?? '');

0 commit comments

Comments
 (0)