Branch Coverage

blib/lib/Crypt/X509.pm
Criterion Covered Total %
branch 89 146 60.9


line true false branch
100 2 9 if (not defined $parser or $parser->error)
156 0 1 if $v == 0
157 0 1 if $v == 1
158 1 0 if $v == 2
198 0 0 if ($self->{'tbsCertificate'}{'validity'}{'notBefore'}{'utcTime'}) { }
0 0 elsif ($self->{'tbsCertificate'}{'validity'}{'notBefore'}{'generalTime'}) { }
226 2 2 if ($self->{'tbsCertificate'}{'validity'}{'notAfter'}{'utcTime'}) { }
2 0 elsif ($self->{'tbsCertificate'}{'validity'}{'notAfter'}{'generalTime'}) { }
307 2 0 if ($self->PubKeyAlg eq 'RSA') { }
385 12 0 if ($oid2attr{$i->{'type'}}) { }
403 3 11 if ($i->{'type'} eq $oid)
524 12 0 if ($oid2attr{$i->{'type'}}) { }
542 3 12 if ($i->{'type'} eq $oid)
655 0 3 unless (defined $exts)
658 3 2 if ($ext->{'extnID'} eq '2.5.29.15')
661 0 3 if ($parsKeyU->error)
667 3 0 if ($ext->{'critical'})
668 3 0 if ($keyu & 32768)
669 0 3 if ($keyu & 16384)
670 2 1 if ($keyu & 8192)
671 2 1 if ($keyu & 4096)
672 1 2 if ($keyu & 2048)
673 0 3 if ($keyu & 1024)
674 0 3 if ($keyu & 512)
675 0 3 if ($keyu & 256)
676 0 3 if ($keyu & 128)
710 0 2 unless (defined $exts)
713 2 12 if ($ext->{'extnID'} eq '2.5.29.37')
714 1 1 if defined $ext->{'oids'}
717 0 1 if ($parsExtKeyUsage->error)
721 0 2 unless $oid2extkeyusage{$_}
722 0 1 if ($ext->{'critical'})
748 0 1 unless (defined $exts)
751 1 4 if ($ext->{'extnID'} eq '2.5.29.17')
754 0 1 if ($parsSubjAlt->error)
776 0 7 unless (defined $exts)
778 6 1 if (defined $self->{'tbsCertificate'}{'AuthorityKeyIdentifier'})
782 1 9 if ($ext->{'extnID'} eq '2.5.29.35')
785 0 1 if ($pars->error)
811 0 1 if (not defined $rdn) { }
821 3 0 if ($oid2attr{$i->{'type'}}) { }
836 0 6 if (not defined $rdn) { }
843 3 12 if ($i->{'type'} eq $oid)
870 0 0 if (defined $self->_AuthorityKeyIdentifier)
950 0 1 unless (defined $exts)
953 1 1 if ($ext->{'extnID'} eq '2.5.29.31')
957 0 1 if ($crlp->error)
982 0 1 unless (defined $extensions)
985 1 0 if ($extension->{'extnID'} eq '2.5.29.31')
992 1 1 if (exists $each_fullName->{'directoryName'}) { }
1 0 elsif (exists $each_fullName->{'uniformResourceIdentifier'}) { }
1020 6 0 if ($oid2attr{$i->{'type'}}) { }
1043 0 0 unless (defined $extensions)
1046 0 0 if ($extension->{'extnID'} eq '2.5.29.32')
1075 0 1 unless (defined $extensions)
1078 1 6 if ($extension->{'extnID'} eq '1.2.840.113533.7.65.0')
1106 0 0 unless (defined $extensions)
1109 0 0 if ($extension->{'extnID'} eq '2.5.29.9')
1137 0 1 unless (defined $extensions)
1140 1 1 if ($extension->{'extnID'} eq '2.5.29.19')
1141 1 0 if ($extension->{'critical'})
1169 0 1 unless (defined $extensions)
1171 0 1 if (defined $self->{'tbsCertificate'}{'SubjectKeyIdentifier'})
1175 1 3 if ($extension->{'extnID'} eq '2.5.29.14')
1178 0 1 if ($parser->error)
1215 0 1 unless (defined $extensions)
1218 1 2 if ($extension->{'extnID'} eq '1.3.6.1.5.5.7.1.11')
1255 0 1 unless (defined $extensions)
1258 1 5 if ($extension->{'extnID'} eq '1.3.6.1.4.1.3401.8.1.1')
1261 0 1 if ($pgpextension->{'version'} != 0) { }
1266 1 0 if exists $pgpextension->{'keyCreation'}{$timetype}
1279 2 15 if (not defined $what or '' eq $what)
1280 1 16 unless (defined $asn)