line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Duadua::Parser::Bot::SMTBot; |
2
|
6
|
|
|
6
|
|
731
|
use strict; |
|
6
|
|
|
|
|
13
|
|
|
6
|
|
|
|
|
151
|
|
3
|
6
|
|
|
6
|
|
30
|
use warnings; |
|
6
|
|
|
|
|
13
|
|
|
6
|
|
|
|
|
121
|
|
4
|
6
|
|
|
6
|
|
35
|
use Duadua::Util qw//; |
|
6
|
|
|
|
|
21
|
|
|
6
|
|
|
|
|
898
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
sub try { |
7
|
41
|
|
|
41
|
1
|
111
|
my ($class, $d) = @_; |
8
|
|
|
|
|
|
|
|
9
|
41
|
100
|
|
|
|
100
|
if ( index($d->ua, 'similartech.com') > -1 ) { |
10
|
8
|
|
|
|
|
41
|
my $h = { |
11
|
|
|
|
|
|
|
name => 'SMTBot', |
12
|
|
|
|
|
|
|
is_bot => 1, |
13
|
|
|
|
|
|
|
}; |
14
|
|
|
|
|
|
|
|
15
|
8
|
100
|
|
|
|
27
|
if ($d->opt_version) { |
16
|
4
|
|
|
|
|
12
|
my ($version) = ($d->ua =~ m! SMTBot/([\d.]+)!); |
17
|
4
|
50
|
|
|
|
23
|
$h->{version} = $version if $version; |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
8
|
|
|
|
|
40
|
return Duadua::Util->set_os($d, $h); |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
__END__ |