line |
true |
false |
branch |
19
|
0 |
11 |
unless $attr{'acl_file'} |
21
|
10 |
1 |
if (-e $attr{'acl_file'}) { } |
33
|
0 |
10 |
unless open ACL, '<', $self->{'acl_file'} |
38
|
4 |
154 |
if $line =~ /^#/ |
39
|
143 |
11 |
unless $self->{'pedantic'} |
43
|
38 |
116 |
unless $line |
46
|
4 |
112 |
if ($line =~ /^\s+(.+)$/) { } |
56
|
4 |
112 |
if ($nextline and $nextline =~ /^[ \t]+\S/) |
60
|
0 |
112 |
unless $statement |
62
|
37 |
75 |
if ($statement =~ /^\[\s*(.+?)\s*\]$/) { } |
65
|
22 |
15 |
unless ($current_resource =~ /^(?:groups|aliases)$/) |
73
|
2 |
73 |
unless ($k) |
78
|
23 |
50 |
if ($current_resource eq 'groups') { } |
|
7 |
43 |
elsif ($current_resource eq 'aliases') { } |
86
|
1 |
42 |
unless ($v =~ /^[rw\s]*$/) |
89
|
43 |
0 |
if (my $resource = $self->resource($current_resource)) { } |
101
|
5 |
5 |
unless (ref $self->{'acl'}{'aliases'} eq 'HASH') |
113
|
5 |
3 |
if ($self->groups) |
123
|
5 |
20 |
if ($k =~ /^@(.*)/) { } |
|
2 |
18 |
elsif ($k =~ /^&(.*)/) { } |
124
|
1 |
4 |
unless ($groups{$1}) |
128
|
1 |
1 |
unless ($self->aliases->{$1}) |
137
|
21 |
1 |
if (defined $resource and $resource->authorized) |
139
|
9 |
32 |
if ($k =~ /^@(.*)/) { } |
|
2 |
30 |
elsif ($k =~ /^&(.*)/) { } |
140
|
3 |
6 |
unless ($groups{$1}) |
144
|
1 |
1 |
unless ($self->aliases->{$1}) |
153
|
3 |
5 |
scalar @errors ? : |
160
|
1 |
5 |
if (my $error = $self->verify_acl) |
164
|
0 |
5 |
if (ref \$out eq 'GLOB' or ref $out) { } |
168
|
5 |
0 |
unless $out |
169
|
0 |
5 |
unless open ACL, '>', $out |
173
|
2 |
3 |
if (scalar keys %{$self->aliases;}) |
182
|
3 |
2 |
if ($self->groups) |
191
|
13 |
1 |
if (defined $resource and $resource->authorized) |
207
|
0 |
0 |
if (my $error = $self->verify_acl) |
215
|
0 |
0 |
if (scalar keys %{$self->aliases;}) |
221
|
0 |
0 |
if ($self->groups) |
226
|
0 |
0 |
if ($self->resources) |
234
|
0 |
0 |
length $_ >= $max_len ? : |
237
|
0 |
0 |
unless open ACL, '>', $self->{'acl_file'} |
240
|
0 |
0 |
if (scalar keys %{$self->aliases;}) |
249
|
0 |
0 |
if ($self->groups) |
258
|
0 |
0 |
if (defined $resource and $resource->authorized) |
281
|
5 |
2 |
if (exists $self->{'acl'}{'aliases'}{$alias_name}) |
290
|
1 |
13 |
unless (ref $self->{'acl'}{'aliases'} eq 'HASH') |
298
|
1 |
29 |
if ($resource_name eq 'name') |
304
|
1 |
15 |
if $entry eq 'authorized' |
306
|
1 |
14 |
if (ref $entry eq 'HASH') { } |
|
0 |
14 |
elsif (ref $entry eq 'ARRAY') { } |
318
|
0 |
30 |
if ($self->resource($resource_name)) { } |
|
0 |
30 |
elsif (not $resource_name =~ m[^(?:\S+\:)?/.*$]) { } |
336
|
29 |
9 |
unless $resource->name eq $resource_name |
338
|
8 |
1 |
scalar @resources ? : |
343
|
91 |
14 |
if (ref $self->{'acl'}{'resources'} eq 'ARRAY') { } |
353
|
52 |
164 |
if defined $resource and $resource->name eq $resource_name |
362
|
20 |
4 |
unless $self->{'pedantic'} |
364
|
0 |
24 |
if ($self->group($group_name)) { } |
383
|
0 |
1 |
unless $group->name eq $group_name |
386
|
0 |
1 |
scalar @groups ? : |
391
|
89 |
16 |
if (ref $self->{'acl'}{'groups'} eq 'ARRAY') { } |
401
|
52 |
90 |
if defined $group and $group->name eq $group_name |
409
|
52 |
15 |
ref $_[$#_] eq 'ARRAY' ? : |
412
|
28 |
39 |
if ($e =~ /^\@(.+)/) { } |
|
3 |
36 |
elsif ($e =~ /^\&(.+)/) { } |
414
|
6 |
22 |
if (grep(($_ eq $e), @$seen)) |
419
|
21 |
1 |
if $self->group($1) |
424
|
2 |
1 |
if $self->alias($1) |