[Netpass-devel] NetPass/www/htdocs/Admin/reports byclient.mhtml,1.7,1.8 bynet.mhtml,1.9,1.10 byos.mh
Brought to you by:
jeffmurphy
From: jeff m. <jef...@us...> - 2006-02-07 19:54:43
|
Update of /cvsroot/netpass/NetPass/www/htdocs/Admin/reports In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12306/www/htdocs/Admin/reports Modified Files: byclient.mhtml bynet.mhtml byos.mhtml Log Message: fixed perm bugs on various admin forms, bug#1426340 bug#1426335 Index: byclient.mhtml =================================================================== RCS file: /cvsroot/netpass/NetPass/www/htdocs/Admin/reports/byclient.mhtml,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- byclient.mhtml 5 Jan 2006 21:02:35 -0000 1.7 +++ byclient.mhtml 7 Feb 2006 19:54:33 -0000 1.8 @@ -27,8 +27,14 @@ } --></script> + <%perl> +if (! ($m->comp('/Admin/MemberOf', 'acl' => [ 'Admin', 'Reports' ]))[0] ) { + print $q->p({-class=>'error'}, "Sorry, permission denied.<BR>(You must be an Admin or in the Reports group)"); + return; +} + use Time::HiRes qw(gettimeofday tv_interval); use NetPass::Network qw (cidr2int searchArpCache int2cidr ip2int int2ip); Index: bynet.mhtml =================================================================== RCS file: /cvsroot/netpass/NetPass/www/htdocs/Admin/reports/bynet.mhtml,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- bynet.mhtml 19 Sep 2005 15:26:56 -0000 1.9 +++ bynet.mhtml 7 Feb 2006 19:54:33 -0000 1.10 @@ -15,11 +15,17 @@ <%perl> +if (! ($m->comp('/Admin/MemberOf', 'acl' => [ 'Admin', 'Reports' ]))[0] ) { + print $q->p({-class=>'error'}, "Sorry, permission denied.<BR>(You must be an Admin or in the Reports group)"); + return; +} + use Time::HiRes qw(gettimeofday tv_interval); use NetPass::Network qw (cidr2int searchArpCache int2cidr ip2int int2ip allOnesBroadcast); use Net::Ping::External qw(ping); + if ( $m->comp('/Admin/Login', %ARGS) ) { my $t0 = [gettimeofday]; Index: byos.mhtml =================================================================== RCS file: /cvsroot/netpass/NetPass/www/htdocs/Admin/reports/byos.mhtml,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- byos.mhtml 29 Jul 2005 01:14:16 -0000 1.8 +++ byos.mhtml 7 Feb 2006 19:54:33 -0000 1.9 @@ -22,6 +22,11 @@ my @cols; my @vals; +if (! ($m->comp('/Admin/MemberOf', 'acl' => [ 'Admin', 'Reports' ]))[0] ) { + print $q->p({-class=>'error'}, "Sorry, permission denied.<BR>(You must be an Admin or in the Reports group)"); + return; +} + if ( $m->comp('/Admin/Login', %ARGS) ) { my $data = get_OS_data($dbh); |