This will prevent people mounting the root path.
They should use the full webdav path instead.
Fixes #4923
}
// Handle WebDAV
if ($_SERVER['REQUEST_METHOD'] == 'PROPFIND') {
- header('location: ' . OC_Helper::linkToRemote('webdav'));
+ // not allowed any more to prevent people
+ // mounting this root directly.
+ // Users need to mount remote.php/webdav instead.
+ header('HTTP/1.1 405 Method Not Allowed');
+ header('Status: 405 Method Not Allowed');
return;
}