Skip to content

Commit

Permalink
Use the 'HTTPDigestAuthentication' instance by default instead of a '…
Browse files Browse the repository at this point in the history
…HTTPBasicAuthentication' instance in the server's options
  • Loading branch information
AdrienCastex committed Jun 12, 2017
1 parent 318e526 commit 0795df3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions lib/server/WebDAVServerOptions.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var HTTPBasicAuthentication_1 = require("../user/authentication/HTTPBasicAuthentication");
var HTTPDigestAuthentication_1 = require("../user/authentication/HTTPDigestAuthentication");
var FakePrivilegeManager_1 = require("../user/privilege/FakePrivilegeManager");
var SimpleUserManager_1 = require("../user/simple/SimpleUserManager");
var RootResource_1 = require("../resource/std/RootResource");
var WebDAVServerOptions = (function () {
function WebDAVServerOptions() {
this.requireAuthentification = false;
this.httpAuthentication = new HTTPBasicAuthentication_1.HTTPBasicAuthentication('default realm');
this.httpAuthentication = new HTTPDigestAuthentication_1.HTTPDigestAuthentication('default realm');
this.privilegeManager = new FakePrivilegeManager_1.FakePrivilegeManager();
this.rootResource = new RootResource_1.RootResource();
this.userManager = new SimpleUserManager_1.SimpleUserManager();
Expand Down
3 changes: 2 additions & 1 deletion src/server/WebDAVServerOptions.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { HTTPBasicAuthentication } from '../user/authentication/HTTPBasicAuthentication'
import { HTTPDigestAuthentication } from '../user/authentication/HTTPDigestAuthentication'
import { FakePrivilegeManager } from '../user/privilege/FakePrivilegeManager'
import { HTTPAuthentication } from '../user/authentication/HTTPAuthentication'
import { IPrivilegeManager } from '../user/privilege/IPrivilegeManager'
Expand All @@ -11,7 +12,7 @@ import { Writable } from 'stream'
export class WebDAVServerOptions
{
requireAuthentification ?: boolean = false
httpAuthentication ?: HTTPAuthentication = new HTTPBasicAuthentication('default realm')
httpAuthentication ?: HTTPAuthentication = new HTTPDigestAuthentication('default realm')
privilegeManager ?: IPrivilegeManager = new FakePrivilegeManager()
rootResource ?: IResource = new RootResource()
userManager ?: IUserManager = new SimpleUserManager()
Expand Down

0 comments on commit 0795df3

Please sign in to comment.