diff options
author | Morris Jobke <hey@morrisjobke.de> | 2015-08-25 19:31:25 +0300 |
---|---|---|
committer | Morris Jobke <hey@morrisjobke.de> | 2015-08-25 19:31:25 +0300 |
commit | 4942646adae206bc79ce5fb1ab25d942deb45151 (patch) | |
tree | 97092e28d8d41944dadb0637d84bf06391f7e12d | |
parent | 67c68253a2dec9c11159cb74673ba977a2e6c2de (diff) | |
parent | 595381b9bd5676492ff8957de0590982ed1864a4 (diff) |
Merge pull request #18560 from owncloud/ext-objectstore-stable8
[stable8] Prevent objectstore being set from client side
-rw-r--r-- | apps/files_external/lib/config.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/apps/files_external/lib/config.php b/apps/files_external/lib/config.php index ddfab439879..8eb968e2d4b 100644 --- a/apps/files_external/lib/config.php +++ b/apps/files_external/lib/config.php @@ -490,6 +490,11 @@ class OC_Mount_Config { return false; } + if (isset($classOptions['objectstore'])) { + // objectstore cannot be set by client side + return false; + } + if (!isset($backends[$class])) { // invalid backend return false; @@ -843,6 +848,13 @@ class OC_Mount_Config { $mountPoint[$applicable][$mountPath]['priority'] = $data[$mountType][$applicable][$mountPath]['priority']; } + // Persistent objectstore + if (isset($data[$mountType][$applicable][$mountPath]) + && isset($data[$mountType][$applicable][$mountPath]['objectstore']) + ) { + $mountPoint[$applicable][$mountPath]['objectstore'] + = $data[$mountType][$applicable][$mountPath]['objectstore']; + } $data[$mountType][$applicable] = array_merge($data[$mountType][$applicable], $mountPoint[$applicable]); } else { |