Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
die_coolen_jungs
our_own_cloud_project
Commits
331f0196
Commit
331f0196
authored
Mar 24, 2015
by
Vincent Petry
Browse files
Merge pull request #15150 from owncloud/sabre-removerangeexceptionforencryption
Remove range header exception for encryption
parents
a0397686
a1b68b5a
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/private/connector/sabre/filesplugin.php
View file @
331f0196
...
...
@@ -70,7 +70,6 @@ class FilesPlugin extends \Sabre\DAV\ServerPlugin {
$this
->
server
->
on
(
'propPatch'
,
array
(
$this
,
'handleUpdateProperties'
));
$this
->
server
->
on
(
'afterBind'
,
array
(
$this
,
'sendFileIdHeader'
));
$this
->
server
->
on
(
'afterWriteContent'
,
array
(
$this
,
'sendFileIdHeader'
));
$this
->
server
->
on
(
'beforeMethod:GET'
,
array
(
$this
,
'handleRangeHeaders'
));
}
/**
...
...
@@ -178,17 +177,4 @@ class FilesPlugin extends \Sabre\DAV\ServerPlugin {
}
}
/**
* Remove range headers if encryption is enabled.
*
* @param RequestInterface $request
* @param ResponseInterface $response
*/
public
function
handleRangeHeaders
(
RequestInterface
$request
,
ResponseInterface
$response
)
{
if
(
\
OC_App
::
isEnabled
(
'files_encryption'
))
{
// encryption does not support range requests (yet)
$request
->
removeHeader
(
'range'
);
}
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment