--- a/lib/Ius/Dav/Htpasswd.pm Mon Jul 18 13:48:33 2011 +0200
+++ b/lib/Ius/Dav/Htpasswd.pm Mon Jul 18 14:06:28 2011 +0200
@@ -58,7 +58,8 @@
expiry=i
expiry_min=i
expiry_max=i
- dav_base=s
+ dav_base_local=s
+ dav_base_remote=s
htpasswd=s
conf_d=s
www_user=s
@@ -94,7 +95,7 @@
my ( $conf, $user, $pass, $expiry ) = @_;
for (
- qw(expiry expiry_min expiry_max dav_base htpasswd conf_d www_user www_group)
+ qw(expiry expiry_min expiry_max dav_base_local htpasswd conf_d www_user www_group)
)
{
die "Can't determine '$_' - please check configuration"
@@ -104,7 +105,7 @@
$expiry = $conf->{expiry} unless defined $expiry and $expiry ne '';
die 'Invalid input' unless validate $conf, $user, $expiry;
- my $user_dir = "$conf->{dav_base}/$user";
+ my $user_dir = "$conf->{dav_base_local}/$user";
mkdir "$user_dir" or die "Can't mkdir '$user_dir': $!";
my ( $www_user, $www_group ) = @{$conf}{qw(www_user www_group)};
@@ -157,14 +158,14 @@
my $rc;
- for (qw(dav_base htpasswd conf_d)) {
+ for (qw(dav_base_local htpasswd conf_d)) {
die "Can't determine '$_' - please check configuration"
unless defined $conf->{$_};
}
# avoid 'Found = in conditional, should be ==' warnings
no warnings qw(syntax);
- my $user_dir = "$conf->{dav_base}/$user";
+ my $user_dir = "$conf->{dav_base_local}/$user";
my $err;
rmtree( $user_dir, error => $err )
or $rc = -1