diff --git a/lib/Controller/WopiController.php b/lib/Controller/WopiController.php index d11d574fc2..5ed071d06f 100644 --- a/lib/Controller/WopiController.php +++ b/lib/Controller/WopiController.php @@ -163,11 +163,11 @@ public function checkFileInfo($fileId, $access_token) { 'UserExtraInfo' => [], 'UserPrivateInfo' => [], 'UserCanWrite' => $canWriteThroughLock && (bool)$wopi->getCanwrite(), - 'UserCanNotWriteRelative' => $isPublic || $this->encryptionManager->isEnabled() || $wopi->getHideDownload(), + 'UserCanNotWriteRelative' => $isPublic || $this->encryptionManager->isEnabled() || $wopi->getHideDownload() || $wopi->isRemoteToken(), 'PostMessageOrigin' => $wopi->getServerHost(), 'LastModifiedTime' => Helper::toISO8601($file->getMTime()), - 'SupportsRename' => !$isVersion, - 'UserCanRename' => !$isPublic && !$isVersion, + 'SupportsRename' => !$isVersion && !$wopi->isRemoteToken(), + 'UserCanRename' => !$isPublic && !$isVersion && !$wopi->isRemoteToken(), 'EnableInsertRemoteImage' => !$isPublic, 'EnableShare' => $file->isShareable() && !$isVersion && !$isPublic, 'HideUserList' => '',