AuthorizedKey.pm

filter: Statementstmt 100% 25 / 25 Branchbran 100% 2 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 6 / 6 Podpod 100% 1 / 1 totaltotal 100% 34 / 34 CC 3 SCAR 5.6
CC
3
Cov
100%
parse
3.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.8
« AuthorizedKey/SSH1.pm ↑ Summary
1 ###########################################
2 package Net::SSH::AuthorizedKey;
3 ###########################################
4 12 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 12 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 12 ▶use Log::Log4perl qw(:easy);
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 12 ▶use Net::SSH::AuthorizedKey::SSH1;
Subroutine BEGIN: called CC=1 SCAR=0.0
9 12 ▶use Net::SSH::AuthorizedKey::SSH2;
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 ###########################################
12 69 ▶sub parse {
Subroutine parse: called CC=3 SCAR=11.0
Pod documented
13 ###########################################
14 69 my($class, $string) = @_;
15  
16 69 my @subclasses = qw(
17 Net::SSH::AuthorizedKey::SSH1
18 Net::SSH::AuthorizedKey::SSH2
19 );
20  
21 69 for my $subclass ( @subclasses ) {
22 122 DEBUG "Parsing with $subclass: $string";
23 122 my $pk = $subclass->parse( $string );
24 122 ▶ if($pk) {
Branch: 1 branch
BranchTrueFalseTotal
if ($pk) 48 74 122
25 48 DEBUG "Successfully parsed $subclass key";
26 48 return $pk;
27 }
28 }
29  
30 21 return undef;
31 }
32  
33 12 1;
34  
35 __END__
« AuthorizedKey/SSH1.pm ↑ Summary