Skip to content

Commit a59c89e

Browse files
Merge pull request #51396 from nextcloud/backport/51365/stable31
[stable31] fix(dav): Fix share token pattern for base uri extraction
2 parents 5331744 + 51602ae commit a59c89e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

apps/dav/appinfo/v2/publicremote.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777

7878
// Define root url with /public.php/dav/files/TOKEN
7979
/** @var string $baseuri defined in public.php */
80-
preg_match('/(^files\/\w+)/i', substr($requestUri, strlen($baseuri)), $match);
80+
preg_match('/(^files\/[a-z0-9-]+)/i', substr($requestUri, strlen($baseuri)), $match);
8181
$baseuri = $baseuri . $match[0];
8282

8383
$server = $serverFactory->createServer($baseuri, $requestUri, $authPlugin, function (\Sabre\DAV\Server $server) use ($authBackend, $linkCheckPlugin, $filesDropPlugin) {

0 commit comments

Comments
 (0)