SiteControl/Rule.pm untested

filter: Statementstmt 0.0% 0 / 29 Branchbran n/a Conditioncond 0.0% 0 / 3 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 0.0% 0 / 7 Podpod 0.0% 0 / 3 totaltotal 0.0% 0 / 44 CC 1 SCAR 6.9
CC
1
Cov
0%
new
2.0
grants
2.0
denies
2.0
CRAP 2.0
1 package Apache::SiteControl::Rule;
2  
3 use 5.008;
4 use strict;
5 use warnings;
6 use Carp;
7  
8 our $VERSION = "1.0";
9  
10 sub new {
11 my $proto = shift;
12 my $class = ref($proto) || $proto;
13 my $this = { };
14 bless ($this, $class);
15 return $this;
16 }
17  
18 sub grants($$$$)
19 {
20 my $this = shift;
21 my $user = shift;
22 my $action = shift;
23 my $resource = shift;
24  
25 return 0;
26 }
27  
28 sub denies($$$$)
29 {
30 my $this = shift;
31 my $user = shift;
32 my $action = shift;
33 my $resource = shift;
34  
35 return "Abstract rule denies everything. Do not use.";
36 }
37  
38 1;
39  
40 __END__