summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorLukas Reschke <lukas@statuscode.ch>2017-03-23 19:28:49 +0100
committerGitHub <noreply@github.com>2017-03-23 19:28:49 +0100
commit9039b71a2302a2c23c137c25c1cd1365a23b4b60 (patch)
tree65947f3abe748ec75d806efbc78f30ca41cbd639 /lib
parentf38d36a16167041da7bf528d3822d3ab30c93c1f (diff)
parent9eca1da1dd9534f68672b3164da5ab56df285e42 (diff)
downloadnextcloud-server-9039b71a2302a2c23c137c25c1cd1365a23b4b60.tar.gz
nextcloud-server-9039b71a2302a2c23c137c25c1cd1365a23b4b60.zip
Merge pull request #4000 from nextcloud/backport-27216
allow configuring authType for DAV backend
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Files/Storage/DAV.php12
1 files changed, 10 insertions, 2 deletions
diff --git a/lib/private/Files/Storage/DAV.php b/lib/private/Files/Storage/DAV.php
index 76a6155df24..73cf137181a 100644
--- a/lib/private/Files/Storage/DAV.php
+++ b/lib/private/Files/Storage/DAV.php
@@ -64,6 +64,8 @@ class DAV extends Common {
/** @var string */
protected $user;
/** @var string */
+ protected $authType;
+ /** @var string */
protected $host;
/** @var bool */
protected $secure;
@@ -95,6 +97,9 @@ class DAV extends Common {
$this->host = $host;
$this->user = $params['user'];
$this->password = $params['password'];
+ if (isset($params['authType'])) {
+ $this->authType = $params['authType'];
+ }
if (isset($params['secure'])) {
if (is_string($params['secure'])) {
$this->secure = ($params['secure'] === 'true');
@@ -133,11 +138,14 @@ class DAV extends Common {
}
$this->ready = true;
- $settings = array(
+ $settings = [
'baseUri' => $this->createBaseUri(),
'userName' => $this->user,
'password' => $this->password,
- );
+ ];
+ if (isset($this->authType)) {
+ $settings['authType'] = $this->authType;
+ }
$proxy = \OC::$server->getConfig()->getSystemValue('proxy', '');
if($proxy !== '') {