summaryrefslogtreecommitdiff
path: root/pinyweb/cgi-bin/auth
diff options
context:
space:
mode:
Diffstat (limited to 'pinyweb/cgi-bin/auth')
-rwxr-xr-xpinyweb/cgi-bin/auth/addaccess.cgi2
-rwxr-xr-xpinyweb/cgi-bin/auth/lsaccess.cgi2
-rwxr-xr-xpinyweb/cgi-bin/auth/lsrepo.cgi2
-rwxr-xr-xpinyweb/cgi-bin/auth/newpass.cgi2
-rwxr-xr-xpinyweb/cgi-bin/auth/newrepo.cgi6
-rwxr-xr-xpinyweb/cgi-bin/auth/pinyconfig.cgi4
-rwxr-xr-xpinyweb/cgi-bin/auth/rebuildrepo.cgi2
-rwxr-xr-xpinyweb/cgi-bin/auth/rmaccess.cgi2
-rwxr-xr-xpinyweb/cgi-bin/auth/rmrepo.cgi2
9 files changed, 12 insertions, 12 deletions
diff --git a/pinyweb/cgi-bin/auth/addaccess.cgi b/pinyweb/cgi-bin/auth/addaccess.cgi
index f86c19e..02b9cb1 100755
--- a/pinyweb/cgi-bin/auth/addaccess.cgi
+++ b/pinyweb/cgi-bin/auth/addaccess.cgi
@@ -14,7 +14,7 @@ $q = CGI->new;
print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) && defined( $q->param('n') ) ) {
- unless( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'addaccess', $q->param('r'), $q->param('n') ) == 0 ) {
+ unless( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'addaccess', scalar( $q->param('r') ), scalar( $q->param('n') ) ) == 0 ) {
die( 'Addaccess was unsuccessful.' );
};
} else {
diff --git a/pinyweb/cgi-bin/auth/lsaccess.cgi b/pinyweb/cgi-bin/auth/lsaccess.cgi
index 354ba32..000d794 100755
--- a/pinyweb/cgi-bin/auth/lsaccess.cgi
+++ b/pinyweb/cgi-bin/auth/lsaccess.cgi
@@ -14,7 +14,7 @@ $q = CGI->new;
print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) ) {
- unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'lsaccess', $q->param('r') ) == 0 ) {
+ unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'lsaccess', scalar( $q->param('r') ) ) == 0 ) {
die( 'lsaccess was unsuccessful.' );
};
} else {
diff --git a/pinyweb/cgi-bin/auth/lsrepo.cgi b/pinyweb/cgi-bin/auth/lsrepo.cgi
index 599eb80..3513b5f 100755
--- a/pinyweb/cgi-bin/auth/lsrepo.cgi
+++ b/pinyweb/cgi-bin/auth/lsrepo.cgi
@@ -9,7 +9,7 @@ use CGI;
use IPC::Open2;
-$q = CGI->new;
+#$q = CGI->new;
print( "Content-type: text/plain\n\n");
diff --git a/pinyweb/cgi-bin/auth/newpass.cgi b/pinyweb/cgi-bin/auth/newpass.cgi
index 1031820..b367558 100755
--- a/pinyweb/cgi-bin/auth/newpass.cgi
+++ b/pinyweb/cgi-bin/auth/newpass.cgi
@@ -30,7 +30,7 @@ foreach my $n ( 1 .. 16 ) {
$salt .= "\$";
-my $crypt = crypt( $q->param('p'), $salt );
+my $crypt = crypt( scalar( $q->param('p') ), $salt );
unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'newpasshash', $crypt ) == 0 ) {
die( 'newpass was unsuccessful.' );
diff --git a/pinyweb/cgi-bin/auth/newrepo.cgi b/pinyweb/cgi-bin/auth/newrepo.cgi
index 94b25e9..46c5993 100755
--- a/pinyweb/cgi-bin/auth/newrepo.cgi
+++ b/pinyweb/cgi-bin/auth/newrepo.cgi
@@ -18,14 +18,14 @@ print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) && defined( $q->param('d') ) ) { # repository, description
@cmd = ( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'newrepo', '--batch', '--enable-ikiwiki', $q->param('r') );
- if( defined( $q->param('i') ) && $q->param('i') eq "0" ) {
+ if( defined( scalar( $q->param('i') ) ) && scalar( $q->param('i') ) eq "0" ) {
push( @cmd, '--disable-ikiwiki' );
- } elsif( defined( $q->param('i') ) && $q->param('i') eq "1" ) {
+ } elsif( defined( scalar( $q->param('i') ) ) && scalar( $q->param('i') ) eq "1" ) {
push( @cmd, '--enable-ikiwiki' );
};
if( defined( $q->param('s') ) ) { # source
- push( @cmd, $q->param('s') );
+ push( @cmd, scalar( $q->param('s') ) );
};
unless( open2( OUT, IN, @cmd ) ) {
diff --git a/pinyweb/cgi-bin/auth/pinyconfig.cgi b/pinyweb/cgi-bin/auth/pinyconfig.cgi
index 4fd8e89..f660032 100755
--- a/pinyweb/cgi-bin/auth/pinyconfig.cgi
+++ b/pinyweb/cgi-bin/auth/pinyconfig.cgi
@@ -14,11 +14,11 @@ $q = CGI->new;
print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) && defined( $q->param('n') ) && defined( $q->param('v') ) ) {
- unless( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'pinyconfig', $q->param('r'), $q->param('n'), $q->param('v') ) == 0 ) {
+ unless( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'pinyconfig', scalar( $q->param('r') ), scalar( $q->param('n') ), scalar( $q->param('v') ) ) == 0 ) {
die( 'pinyconfig was unsuccessful.' );
};
} elsif( defined( $q->param('r') ) ) {
- unless( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'pinyconfig', $q->param('r') ) == 0 ) {
+ unless( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'pinyconfig', scalar( $q->param('r') ) ) == 0 ) {
die( 'pinyconfig was unsuccessful.' );
};
} else {
diff --git a/pinyweb/cgi-bin/auth/rebuildrepo.cgi b/pinyweb/cgi-bin/auth/rebuildrepo.cgi
index 912e004..1452573 100755
--- a/pinyweb/cgi-bin/auth/rebuildrepo.cgi
+++ b/pinyweb/cgi-bin/auth/rebuildrepo.cgi
@@ -14,7 +14,7 @@ $q = CGI->new;
print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) ) {
- unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'rebuildrepo', $q->param('r') ) == 0 ) {
+ unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'rebuildrepo', scalar( $q->param('r') ) ) == 0 ) {
die( 'rebuildrepo was unsuccessful.' );
};
} else {
diff --git a/pinyweb/cgi-bin/auth/rmaccess.cgi b/pinyweb/cgi-bin/auth/rmaccess.cgi
index 35736ab..24147ba 100755
--- a/pinyweb/cgi-bin/auth/rmaccess.cgi
+++ b/pinyweb/cgi-bin/auth/rmaccess.cgi
@@ -14,7 +14,7 @@ $q = CGI->new;
print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) && defined( $q->param('n') ) ) {
- unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'rmaccess', $q->param('r'), $q->param('n') ) == 0 ) {
+ unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'rmaccess', scalar( $q->param('r') ), scalar( $q->param('n') ) ) == 0 ) {
die( 'rmaccess was unsuccessful.' );
};
} else {
diff --git a/pinyweb/cgi-bin/auth/rmrepo.cgi b/pinyweb/cgi-bin/auth/rmrepo.cgi
index f57170a..54f1a09 100755
--- a/pinyweb/cgi-bin/auth/rmrepo.cgi
+++ b/pinyweb/cgi-bin/auth/rmrepo.cgi
@@ -14,7 +14,7 @@ $q = CGI->new;
print( "Content-type: text/plain\n\n");
if( defined( $q->param('r') ) ) {
- unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'rmrepo', $q->param('r') ) == 0 ) {
+ unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'rmrepo', scalar( $q->param('r') ) ) == 0 ) {
die( 'rmrepo was unsuccessful.' );
};
} else {