Philipp Dunkel 15 years ago
parent ea867a4c4d
commit 314aec03ad

@ -484,6 +484,28 @@ sub X509extractExpiryDate($)
}
return "";
}
sub CRLuptodate($)
{
# TIMEZONE ?!?
my $data=`$opensslbin crl -in "$_[0]" -noout -lastupdate`; #inform=der ?
#lastUpdate=Aug 8 10:26:34 2007 GMT
if($data=~m/lastUpdate=(\w{2,4}) *(\d{1,2}) *(\d{1,2}:\d{1,2}:\d{1,2}) (\d{4}) GMT/)
{
my $date=sprintf("%04d-%02d-%02d",$4,$monarr{$1},$2);
SysLog "CRL Issueing Date found: $date\n" if($debug);
my $compare = strftime("%Y-%m-%d", localtime);
SysLog "Comparing $date with $compare\n" if($debug);
return $date eq $compare;
}
else
{
SysLog "Expiry Date not found. Perhaps DER format is necessary? Hint: $data\n";
}
return 0;
}
sub X509extractSerialNumber($)
{
# TIMEZONE ?!?
@ -958,7 +980,7 @@ sub RevokeCerts($$)
}
else
{
SysLog("Error: $crtname $!\n") if($debug);
SysLog("Error in RevokeCerts: $crtname $!\n") if($debug);
}
}

Loading…
Cancel
Save