summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorivan <ivan>2001-10-22 14:48:28 +0000
committerivan <ivan>2001-10-22 14:48:28 +0000
commitb7cdcea59f34c12f7d181c41014e0d2559bf983c (patch)
tree6797e05574e600c207de0f1c4252ada03def3eb5
parentf94ef1d2324d55293ba9efeb3a6156a488bbd39f (diff)
fix dir check
-rw-r--r--FS/FS/svc_acct.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/FS/FS/svc_acct.pm b/FS/FS/svc_acct.pm
index 71c47d6cd..8e29cb739 100644
--- a/FS/FS/svc_acct.pm
+++ b/FS/FS/svc_acct.pm
@@ -720,9 +720,10 @@ sub check {
or return "Illegal finger: ". $self->getfield('finger');
$self->setfield('finger', $1);
- $recref->{dir} =~ /^([\/\w\-]*)$/
+ $recref->{dir} =~ /^([\/\w\-\.]*)$/
or return "Illegal directory";
$recref->{dir} = $1;
+ return "Illegal directory" if $recref->{dir} =~ /\.\./; #no ..
unless ( $recref->{dir} ) {
$recref->{dir} = $dir_prefix . '/';
if ( $dirhash > 0 ) {
@@ -920,7 +921,7 @@ sub ssh {
=head1 VERSION
-$Id: svc_acct.pm,v 1.50 2001-10-02 11:10:19 ivan Exp $
+$Id: svc_acct.pm,v 1.51 2001-10-22 14:48:28 ivan Exp $
=head1 BUGS