summaryrefslogtreecommitdiff
path: root/pinyweb/cgi-bin/auth/lsaccess.cgi
blob: 354ba3229005640fac3839ad571c7aba911b149c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/usr/bin/perl
$| = 1;

open(STDERR, ">&STDOUT");

use warnings;

use CGI;

use IPC::Open2;

$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 ) {
    die( 'lsaccess was unsuccessful.' );
  };
} else {
  unless ( system( '/usr/sbin/piny-suid', $ENV{'REMOTE_USER'}, 'lsaccess' ) == 0 ) {
    die( 'lsaccess was unsuccessful.' );
  };
};