File Coverage

blib/lib/Net/IP/Identifier/Plugin/Fedex.pm
Criterion Covered Total %
statement 18 18 100.0
branch n/a
condition 1 3 33.3
subroutine 6 6 100.0
pod 1 2 50.0
total 26 29 89.6


line stmt bran cond sub pod time code
1             #===============================================================================
2             # PODNAME: Net::IP::Identifier::Plugin::Fedex
3             # ABSTRACT: identify Fedex (AS7726 AS27619 AS25676) owned IP addresses
4              
5             #
6             # AUTHOR: Reid Augustin (REID)
7             # EMAIL: reid@hellosix.com
8             # CREATED: Sun Oct 12 19:32:46 PDT 2014
9             #===============================================================================
10              
11 1     1   29 use 5.008;
  1         3  
  1         40  
12 1     1   4 use strict;
  1         1  
  1         35  
13 1     1   4 use warnings;
  1         2  
  1         45  
14              
15             package Net::IP::Identifier::Plugin::Fedex;
16              
17 1     1   5 use Role::Tiny::With;
  1         1  
  1         221  
18             with qw( Net::IP::Identifier_Role );
19              
20             our $VERSION = '0.110'; # VERSION
21              
22             sub new {
23 1     1 1 3 my ($class, %opts) = @_;
24              
25 1         3 my $self = {};
26 1   33     10 bless $self, (ref $class || $class);
27              
28             # List of known Fedex (AS7726 AS27619 AS25676) IP blocks as of May 2015
29 1         6 $self->ips(
30             # 12 Network Blocks
31             '12.168.77.0/24',
32             '65.162.10.0/24',
33             '146.18.0.0/16',
34             '155.161.0.0/16',
35             '165.150.0.0/16',
36             '170.5.0.0/16',
37             '170.170.0.0/16',
38             '192.67.56.0/24',
39             # extending 198.140.0.0/22 to include 198.140.4.0/23
40             '198.140.0.0-198.140.5.255',
41             # extending 199.81.0.0/16 to include 199.82.0.0/16
42             '199.81.0.0-199.82.255.255',
43             '203.208.20.0/24',
44             '204.135.0.0/16',
45             );
46 1         10 return $self;
47             }
48              
49             sub name {
50 3     3 0 15 return 'Fedex';
51             }
52              
53             1;
54              
55             __END__