Apache里开启Webdav,启用如下配置:
Alias /webdav "/webdav" <Directory "/webdav"> Options Indexes FollowSymLinks </Directory> <Location /webdav> DAV On AuthType Basic AuthName "admin" AuthUserFile /etc/apache2/conf-available/webdav.auth Require valid-user </Location>
其中AuthUserFile保存存了用户密码文件,内容格式如下:
#用htpasswd生成 admin:密码
htpasswd生成方法:
htpasswd -c authfile username password