Quantcast
Channel: Public Key Infrastructure PowerShell module
Viewing all articles
Browse latest Browse all 729

Closed Unassigned: Bug in CrlDistributionPoint.cs [49]

$
0
0
Hi

I find a minor bug in CrlDistributionPoint.cs:

Starting at around line 59 you have:
if (CryptoRegistry.Ping(ComputerName)) {
urls = (String[])CryptoRegistry.GetRReg("CRLPublicationURLs", Name, ComputerName);
foreach (String url in urls) {
cdps.Add(new CDP(url));
}
} else {
if (CertificateAuthority.Ping(ComputerName)) {
urls = (String[])CryptoRegistry.GetRegFallback(ConfigString, String.Empty, "CRLPublicationURLs"); } else {
ServerUnavailableException e = new ServerUnavailableException(DisplayName);
e.Data.Add("Source", (OfflineSource)3);
throw e; }
}
foreach (String url in urls) { cdps.Add(new CDP(url)); }
m_cdp = cdps.ToArray();

If the CDP is accessed through the CryptoRegistry the list of CDPs is added twice.

I suggest that the foreach at line 61/62 is deleted.

Peter

Viewing all articles
Browse latest Browse all 729

Trending Articles