public void UpdateCertificate(string certRef) { if (UsePowershell) { powershellManager.UpdateCertificate(certRef); } else { var cmd = new ACMESharp.POSH.UpdateCertificate(); cmd.CertificateRef = certRef; cmd.ExecuteCommand(); } }
public void UpdateAndExportCertificate(string domainAlias) { var certRef = "cert_" + domainAlias; try { powershellManager.UpdateCertificate(certRef); if (!CertExists(domainAlias)) { var certInfo = GetCertificate(certRef); string certId = "=" + certInfo.Id.ToString(); //ExportCertificate(certId); if (!CertExists(domainAlias)) { //if we have our first cert files, lets export the pfx as well ExportCertificate(certId, pfxOnly: true); } } } catch (Exception exp) { System.Diagnostics.Debug.WriteLine(exp.ToString()); } }
public void UpdateAndExportCertificate(string certAlias) { try { powershellManager.UpdateCertificate(certAlias); ReloadVaultConfig(); var certInfo = GetCertificate(certAlias); // if we have our first cert files, lets export the pfx as well ExportCertificate(certAlias, pfxOnly: true); } catch (Exception exp) { System.Diagnostics.Debug.WriteLine(exp.ToString()); } }