162 references to Log
Templates.Tests (162)
src\Shared\CertificateGeneration\CertificateManager.cs (78)
139
Log
.ListCertificatesStart(location, storeName);
150
if (
Log
.IsEnabled())
152
Log
.DescribeFoundCertificates(ToCertificateDescription(matchingCertificates));
159
Log
.CheckCertificatesValidity();
166
if (
Log
.IsEnabled())
169
Log
.DescribeValidCertificates(ToCertificateDescription(validCertificates));
170
Log
.DescribeInvalidCertificates(ToCertificateDescription(invalidCertificates));
178
if (
Log
.IsEnabled())
181
Log
.DescribeMinimumVersionCertificates(ToCertificateDescription(validMinVersionCertificates));
182
Log
.DescribeBelowMinimumVersionCertificates(ToCertificateDescription(belowMinimumVersionCertificates));
196
Log
.ListCertificatesEnd();
201
if (
Log
.IsEnabled())
203
Log
.ListCertificatesError(e.ToString());
304
if (
Log
.IsEnabled())
307
Log
.FilteredCertificates(ToCertificateDescription(filteredCertificates));
308
Log
.ExcludedCertificates(ToCertificateDescription(excludedCertificates));
330
if (
Log
.IsEnabled())
332
Log
.CorrectCertificateStateStart(GetDescription(candidate));
335
Log
.CorrectCertificateStateEnd();
339
if (
Log
.IsEnabled())
341
Log
.CorrectCertificateStateError(e.ToString());
355
if (
Log
.IsEnabled())
357
Log
.ValidCertificatesFound(ToCertificateDescription(certificates));
360
if (
Log
.IsEnabled())
362
Log
.SelectedCertificate(GetDescription(certificate));
369
Log
.NoValidCertificatesFound();
372
Log
.CreateDevelopmentCertificateStart();
378
if (
Log
.IsEnabled())
380
Log
.CreateDevelopmentCertificateError(e.ToString());
385
Log
.CreateDevelopmentCertificateEnd();
393
Log
.SaveCertificateInStoreError(e.ToString());
402
if (
Log
.IsEnabled())
404
Log
.CorrectCertificateStateStart(GetDescription(certificate));
407
Log
.CorrectCertificateStateEnd();
411
if (
Log
.IsEnabled())
413
Log
.CorrectCertificateStateError(e.ToString());
441
if (
Log
.IsEnabled())
443
Log
.ExportCertificateError(e.ToString());
504
Log
.ImportCertificateMissingFile(certificatePath);
511
if (
Log
.IsEnabled())
513
Log
.ImportCertificateExistingCertificates(ToCertificateDescription(certificates));
521
Log
.LoadCertificateStart(certificatePath);
523
if (
Log
.IsEnabled())
525
Log
.LoadCertificateEnd(GetDescription(certificate));
530
if (
Log
.IsEnabled())
532
Log
.LoadCertificateError(e.ToString());
542
if (
Log
.IsEnabled())
544
Log
.NoHttpsDevelopmentCertificate(GetDescription(certificate));
555
if (
Log
.IsEnabled())
557
Log
.SaveCertificateInStoreError(e.ToString());
570
if (
Log
.IsEnabled())
573
Log
.FilteredCertificates(ToCertificateDescription(filteredCertificates));
574
Log
.ExcludedCertificates(ToCertificateDescription(excludedCertificates));
606
if (
Log
.IsEnabled())
608
Log
.ExportCertificateStart(GetDescription(certificate), path, includePrivateKey);
613
Log
.NoPasswordForCertificate();
619
Log
.CreateExportCertificateDirectory(targetDirectoryPath);
685
catch (Exception e) when (
Log
.IsEnabled())
687
Log
.ExportCertificateError(e.ToString());
697
Log
.WriteCertificateToDisk(path);
708
catch (Exception ex) when (
Log
.IsEnabled())
710
Log
.WriteCertificateToDiskError(ex.ToString());
725
Log
.WritePemKeyToDisk(keyPath);
736
catch (Exception ex) when (
Log
.IsEnabled())
738
Log
.WritePemKeyToDiskError(ex.ToString());
818
if (
Log
.IsEnabled())
820
Log
.SaveCertificateInStoreStart(GetDescription(certificate), name, location);
825
Log
.SaveCertificateInStoreEnd();
833
if (
Log
.IsEnabled())
835
Log
.TrustCertificateStart(GetDescription(certificate));
838
Log
.TrustCertificateEnd();
841
catch (Exception ex) when (
Log
.IsEnabled())
843
Log
.TrustCertificateError(ex.ToString());
962
if (
Log
.IsEnabled())
964
Log
.RemoveCertificateFromUserStoreStart(GetDescription(certificate));
967
Log
.RemoveCertificateFromUserStoreEnd();
969
catch (Exception ex) when (
Log
.IsEnabled())
971
Log
.RemoveCertificateFromUserStoreError(ex.ToString());
src\Shared\CertificateGeneration\MacOSCertificateManager.cs (26)
91
Log
.MacOSCertificateAlreadyTrusted();
100
if (
Log
.IsEnabled())
102
Log
.MacOSTrustCommandStart($"{MacOSTrustCertificateCommandLine} {MacOSTrustCertificateCommandLineArguments}{tmpFile}");
109
Log
.MacOSTrustCommandError(process.ExitCode);
113
Log
.MacOSTrustCommandEnd();
146
Log
.MacOSAddCertificateToUserProfileDirError(candidate.Thumbprint, ex.Message);
200
Log
.MacOSRemoveCertificateTrustRuleStart(GetDescription(certificate));
219
Log
.MacOSRemoveCertificateTrustRuleError(process.ExitCode);
222
Log
.MacOSRemoveCertificateTrustRuleEnd();
252
if (
Log
.IsEnabled())
254
Log
.MacOSRemoveCertificateFromKeyChainStart(keychain, GetDescription(certificate));
264
Log
.MacOSRemoveCertificateFromKeyChainError(process.ExitCode);
271
Log
.MacOSRemoveCertificateFromKeyChainEnd();
315
if (
Log
.IsEnabled())
317
Log
.MacOSAddCertificateToUserProfileDirStart(MacOSUserKeychain, GetDescription(certificate));
327
Log
.MacOSAddCertificateToUserProfileDirError(certificate.Thumbprint, ex.Message);
330
Log
.MacOSAddCertificateToKeyChainEnd();
331
Log
.MacOSAddCertificateToUserProfileDirEnd();
353
if (
Log
.IsEnabled())
355
Log
.MacOSAddCertificateToKeyChainStart(MacOSUserKeychain, GetDescription(certificate));
365
Log
.MacOSAddCertificateToKeyChainError(process.ExitCode, output);
370
Log
.MacOSAddCertificateToKeyChainEnd();
436
Log
.MacOSDiskStoreDoesNotExist();
450
Log
.MacOSFileIsNotAValidCertificate(file);
471
Log
.MacOSRemoveCertificateFromUserProfileDirError(certificate.Thumbprint, ex.Message);
488
Log
.DirectoryPermissionsNotSecure(dirInfo.FullName);
src\Shared\CertificateGeneration\UnixCertificateManager.cs (51)
64
Log
.UnixOpenSslCertificateDirectoryOverrideIgnored(OpenSslCertDirectoryOverrideVariableName);
83
Log
.UnixNotTrustedByDotnet();
105
Log
.UnixNotTrustedByOpenSsl(OpenSslCertificateDirectoryVariableName);
132
Log
.UnixNotTrustedByOpenSsl(OpenSslCertificateDirectoryVariableName);
143
Log
.UnixMissingCertUtilCommand(CertUtilCommand);
157
Log
.UnixNotTrustedByNss(nssDb.Path, nssDb.IsFirefox ? BrowserFamilyFirefox : BrowserFamilyChromium);
222
Log
.UnixDotnetTrustSucceeded();
228
Log
.UnixDotnetTrustException(ex.Message);
253
Log
.UnixNotOverwritingCertificate(certPath);
262
Log
.UnixNotOverwritingCertificate(certPath);
288
Log
.UnixMissingOpenSslCommand(OpenSslCommand);
293
Log
.UnixOpenSslTrustSucceeded();
299
Log
.UnixOpenSslTrustFailed();
309
Log
.UnixMissingCertUtilCommand(CertUtilCommand);
319
Log
.UnixNssDbTrustSucceeded(nssDb.Path);
326
Log
.UnixNssDbTrustFailedWithProbableConflict(nssDb.Path, nssDb.IsFirefox ? BrowserFamilyFirefox : BrowserFamilyChromium);
332
Log
.UnixNssDbTrustFailed(nssDb.Path, nssDb.IsFirefox ? BrowserFamilyFirefox : BrowserFamilyChromium);
343
Log
.UnixTrustPartiallySucceeded();
392
Log
.UnixOpenSslCertificateDirectoryAlreadyConfigured(prettyCertDir, OpenSslCertificateDirectoryVariableName);
398
Log
.UnixSuggestAppendingToEnvironmentVariable(prettyCertDir, OpenSslCertificateDirectoryVariableName);
404
Log
.UnixSuggestSettingEnvironmentVariable(prettyCertDir, Path.Combine(openSslDir, "certs"), OpenSslCertificateDirectoryVariableName);
409
Log
.UnixSuggestSettingEnvironmentVariableWithoutExample(prettyCertDir, OpenSslCertificateDirectoryVariableName);
423
Log
.WslWindowsTrustSucceeded();
427
Log
.WslWindowsTrustFailed();
433
Log
.WslWindowsTrustException(ex.Message);
458
Log
.UnixDotnetUntrustException(ex.Message);
485
Log
.UnixMissingOpenSslCommand(OpenSslCommand);
490
Log
.UnixOpenSslUntrustSucceeded();
495
Log
.UnixOpenSslUntrustFailed();
501
Log
.UnixOpenSslUntrustSkipped(certPath);
510
Log
.UnixMissingCertUtilCommand(CertUtilCommand);
518
Log
.UnixNssDbUntrustSucceeded(nssDb.Path);
522
Log
.UnixNssDbUntrustFailed(nssDb.Path);
548
Log
.DirectoryPermissionsNotSecure(dirInfo.FullName);
723
Log
.UnixNssDbCheckException(nssDb.Path, ex.Message);
752
Log
.UnixNssDbAdditionException(nssDb.Path, ex.Message);
782
Log
.UnixNssDbRemovalException(nssDb.Path, ex.Message);
796
Log
.UnixNoFirefoxProfilesFound(firefoxDirectory);
802
Log
.UnixFirefoxProfileEnumerationException(firefoxDirectory, ex.Message);
812
Log
.UnixOpenSslCertificateDirectoryOverridePresent(OpenSslCertDirectoryOverrideVariableName);
828
Log
.UnixCertificateFileDeletionException(certPath, ex.Message);
844
Log
.UnixNssDbOverridePresent(NssDbOverrideVariableName);
854
Log
.UnixNssDbDoesNotExist(nssDb, NssDbOverrideVariableName);
882
Log
.UnixHomeDirectoryDoesNotExist(homeDirectory, Environment.UserName);
948
Log
.UnixOpenSslVersionFailed();
955
Log
.UnixOpenSslVersionParsingFailed();
964
Log
.UnixOpenSslVersionException(ex.Message);
992
Log
.UnixOpenSslHashFailed(certificatePath);
1001
Log
.UnixOpenSslHashException(certificatePath, ex.Message);
1069
Log
.UnixOpenSslRehashTooManyHashes(cert.FullName, hash, MaxHashCollisions);
1076
Log
.UnixOpenSslRehashException(ex.Message);
src\Shared\CertificateGeneration\WindowsCertificateManager.cs (7)
81
Log
.WindowsCertificateAlreadyTrusted();
87
Log
.WindowsAddCertificateToRootStore();
96
Log
.WindowsCertificateTrustCanceled();
103
Log
.WindowsRemoveCertificateFromRootStoreStart();
114
Log
.WindowsRemoveCertificateFromRootStoreNotFound();
117
Log
.WindowsRemoveCertificateFromRootStoreEnd();
163
Log
.DirectoryPermissionsNotSecure(dirInfo.FullName);