diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2018-12-04 11:55:04 +0100 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2018-12-04 11:55:04 +0100 |
commit | 28474612e4f5418bb3c3a9881a04a6e73a16e632 (patch) | |
tree | 83d767d8f0ddbc0467b85249a17e45087467bde7 /apps/dav/lib/Connector | |
parent | a915594b03757a9e7f3f0a266dd29003ac6dd7d0 (diff) | |
download | nextcloud-server-28474612e4f5418bb3c3a9881a04a6e73a16e632.tar.gz nextcloud-server-28474612e4f5418bb3c3a9881a04a6e73a16e632.zip |
Only run the AnonymousOptionsPlugion on Anonymous requests
Fixes #12744
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps/dav/lib/Connector')
-rw-r--r-- | apps/dav/lib/Connector/Sabre/AnonymousOptionsPlugin.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/dav/lib/Connector/Sabre/AnonymousOptionsPlugin.php b/apps/dav/lib/Connector/Sabre/AnonymousOptionsPlugin.php index b69c1e0286c..390cb4a9c67 100644 --- a/apps/dav/lib/Connector/Sabre/AnonymousOptionsPlugin.php +++ b/apps/dav/lib/Connector/Sabre/AnonymousOptionsPlugin.php @@ -50,7 +50,7 @@ class AnonymousOptionsPlugin extends ServerPlugin { * @return bool */ public function handleAnonymousOptions(RequestInterface $request, ResponseInterface $response) { - if ($request->getMethod() === 'OPTIONS') { + if ($request->getHeader('Authorization') === null && $request->getMethod() === 'OPTIONS') { /** @var CorePlugin $corePlugin */ $corePlugin = $this->server->getPlugin('core'); // setup a fake tree for anonymous access |