line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
#$Id: UseLighttpd.pm,v 1.1 2005/11/14 03:39:09 naoya Exp $ |
2
|
|
|
|
|
|
|
package Acme::Web20::Validator::Rule::UseLighttpd; |
3
|
2
|
|
|
2
|
|
1001
|
use strict; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
73
|
|
4
|
2
|
|
|
2
|
|
13
|
use warnings; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
67
|
|
5
|
2
|
|
|
2
|
|
11
|
use base qw (Acme::Web20::Validator::Rule); |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
380
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
__PACKAGE__->name('Served by lighttpd?'); |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub validate { |
10
|
1
|
|
|
1
|
0
|
2
|
my ($self, $res) = @_; |
11
|
1
|
|
33
|
|
|
8
|
$self->is_ok( |
12
|
|
|
|
|
|
|
$res->headers->header('Server') && |
13
|
|
|
|
|
|
|
$res->headers->header('Server') =~ m!lighttpd! |
14
|
|
|
|
|
|
|
); |
15
|
|
|
|
|
|
|
} |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
1; |