#!/usr/bin/perl print "Certificates:\n\n"; my @arr = glob('/etc/ssl/*.crt'); foreach my $file (@arr) { ($n,$n,$n,$file1) = split("/", $file); ($file1) = split(".crt", $file1); print "$file1 \n"; system("openssl x509 -in $file -text -noout |grep 'Issuer:'"); system("openssl x509 -in $file -text -noout |grep 'Not '"); print "\n"; }