SOLVED

Renew SharePoint 2013 Workflow Certificates

Copper Contributor

My certificate will be expiring soon in SP workflow 2013.  I am using the certificate the WFM creates when I setup the WF farm.  I am still on CU3 as I've run into issues in the past.  On a few other farms, I tried installing CU4 and CU5 to get the PowerShell commands to be able to renew the certs.  However, each time the updates stalled out leaving me with no other option but to recreate the WF farm.

 

2 questions:

1. can I just install CU4 and CU5 without needing to remove the WF servers from the farm, stop any services or anything else?

2. Is there a better documented process than this one?

https://dellenny.com/how-to-modify-the-workflow-manager-certificates-before-they-expire-using-auto-g...

1 Reply
best response confirmed by thekurteichler (Copper Contributor)
Solution

@thekurteichler 

The link you had provided is accurate but pertinent information like WFM 1.0 CU5 requires SQL2012 SP4 or above is required and that if you are running SharePoint 2016 then you should be running Service Bus 1.1.

 

But to answer your question in regards to renewing auto-generated certificates for Workflow Manager and Service, you may proceed with the process without applying WFM1.0 CU4 and WFM1.0 CU5 if you meet the following conditions:

  1. Still part of the WFM farm during process
  2. Ensure that WFM powershell commands "Get-WFFarm" and "Get-SBFarm" certificate results have "IsGenerated=True"
  3. If WFM farm is a 3 node farm, have WFMNode2 and WFMNode3 leave the WFM farm using Workflow Manager Configuration Wizard. To determine which is the primary WFM node or WFMNode1 - go to IIS and validate Workflow Management Website bindings for HTTPS and server name of primary WFM node should be displayed.

The process to reset WFM Passphrase and reset certificate generation key:

1) Run below WFM powershell command to change passphrase and thumbprints:

$CertKey=convertto-securestring ‘PASSPHRASE’ -asplaintext -force;

Set-WFCertificateAutoGenerationKey –Key $CertKey

Set-SBCertificateAutogenerationKey –Key $CertKey

 

Then run:

Stop-SBFarm

Update-SBHost

 

  • This step will create 3 certificates under IIS Server certificates:
    1. Service Bus Root Certificate – ‘Issued To’ and ‘Issued By’ = AppServerGeneratedSBCA
    2. Service Bus Encryption Certificate – ‘Issued To = Server Name’ and ‘Issued By’ = AppServerGeneratedSBCA
    3. Workflow Manager Encryption Certificate - ‘Issued To’ and ‘Issued By’ = Server Name
  • Note that Workflow Outbound certificate is not populated

2) Run Workflow Manager Configuration Wizard - leave WFM farm first and then rejoin WFM farm

 

  • Leaving WFM farm and rejoining will populate Workflow Outbound certificate
  • Refresh Server Certificates on IIS, once you have successfully rejoined WFM farm to view certificate

3) If this is a 3 Node WFM farm, have WFMNode2 and WFMNode3 rejoin the farm - new certificates will be automatically added.

 

4) Follow below article to export WFM certificate to SharePoint CA\Security\Manage Trusts:

SharePoint 2016: Step by Step guide to add Workflow Manager Certificate into SharePoint trust

https://social.technet.microsoft.com/wiki/contents/articles/34451.sharepoint-2016-step-by-step-guide...

 

5) Register WFM to SharePoint - this process adds new Workflow Outbound certificate to SP CA\Security\Manage Trusts

 

From Administrative SharePoint Management Shell, run below command to get current WorkflowHostURI used to register WFM to SharePoint and to validate Scopename:

$wfProxy = Get-SPWorkflowServiceApplicationProxy           

$wfProxy.GetWorkflowServiceAddress((Get-SPSite -Limit 1 -WarningAction SilentlyContinue))

 

Sample command:

Sample command:

Register-SPWorkflowService –SPSite "http://FQDN" –WorkflowHostUri "https://WFM.contoso.com:12290" -AllowOAuthhttp -force

 

Sample command if ScopeName parameter needed:

Register-SPWorkflowService –SPSite "http://FQDN" –WorkflowHostUri "https://WFM.contoso.com:12290" -Scopename SCOPENAME -AllowOAuthhttp -force

 

6) To avoid users getting 401 errors when running 2013 workflows, run below daily timer:
From SharePoint Central Admin\Monitoring\Timer Job Definitions
Run daily timer jobs:
Refresh Trusted Security Token Services Metadata feed [Farm job – Daily]

 

Good luck!!

 

 

1 best response

Accepted Solutions
best response confirmed by thekurteichler (Copper Contributor)
Solution

@thekurteichler 

The link you had provided is accurate but pertinent information like WFM 1.0 CU5 requires SQL2012 SP4 or above is required and that if you are running SharePoint 2016 then you should be running Service Bus 1.1.

 

But to answer your question in regards to renewing auto-generated certificates for Workflow Manager and Service, you may proceed with the process without applying WFM1.0 CU4 and WFM1.0 CU5 if you meet the following conditions:

  1. Still part of the WFM farm during process
  2. Ensure that WFM powershell commands "Get-WFFarm" and "Get-SBFarm" certificate results have "IsGenerated=True"
  3. If WFM farm is a 3 node farm, have WFMNode2 and WFMNode3 leave the WFM farm using Workflow Manager Configuration Wizard. To determine which is the primary WFM node or WFMNode1 - go to IIS and validate Workflow Management Website bindings for HTTPS and server name of primary WFM node should be displayed.

The process to reset WFM Passphrase and reset certificate generation key:

1) Run below WFM powershell command to change passphrase and thumbprints:

$CertKey=convertto-securestring ‘PASSPHRASE’ -asplaintext -force;

Set-WFCertificateAutoGenerationKey –Key $CertKey

Set-SBCertificateAutogenerationKey –Key $CertKey

 

Then run:

Stop-SBFarm

Update-SBHost

 

  • This step will create 3 certificates under IIS Server certificates:
    1. Service Bus Root Certificate – ‘Issued To’ and ‘Issued By’ = AppServerGeneratedSBCA
    2. Service Bus Encryption Certificate – ‘Issued To = Server Name’ and ‘Issued By’ = AppServerGeneratedSBCA
    3. Workflow Manager Encryption Certificate - ‘Issued To’ and ‘Issued By’ = Server Name
  • Note that Workflow Outbound certificate is not populated

2) Run Workflow Manager Configuration Wizard - leave WFM farm first and then rejoin WFM farm

 

  • Leaving WFM farm and rejoining will populate Workflow Outbound certificate
  • Refresh Server Certificates on IIS, once you have successfully rejoined WFM farm to view certificate

3) If this is a 3 Node WFM farm, have WFMNode2 and WFMNode3 rejoin the farm - new certificates will be automatically added.

 

4) Follow below article to export WFM certificate to SharePoint CA\Security\Manage Trusts:

SharePoint 2016: Step by Step guide to add Workflow Manager Certificate into SharePoint trust

https://social.technet.microsoft.com/wiki/contents/articles/34451.sharepoint-2016-step-by-step-guide...

 

5) Register WFM to SharePoint - this process adds new Workflow Outbound certificate to SP CA\Security\Manage Trusts

 

From Administrative SharePoint Management Shell, run below command to get current WorkflowHostURI used to register WFM to SharePoint and to validate Scopename:

$wfProxy = Get-SPWorkflowServiceApplicationProxy           

$wfProxy.GetWorkflowServiceAddress((Get-SPSite -Limit 1 -WarningAction SilentlyContinue))

 

Sample command:

Sample command:

Register-SPWorkflowService –SPSite "http://FQDN" –WorkflowHostUri "https://WFM.contoso.com:12290" -AllowOAuthhttp -force

 

Sample command if ScopeName parameter needed:

Register-SPWorkflowService –SPSite "http://FQDN" –WorkflowHostUri "https://WFM.contoso.com:12290" -Scopename SCOPENAME -AllowOAuthhttp -force

 

6) To avoid users getting 401 errors when running 2013 workflows, run below daily timer:
From SharePoint Central Admin\Monitoring\Timer Job Definitions
Run daily timer jobs:
Refresh Trusted Security Token Services Metadata feed [Farm job – Daily]

 

Good luck!!

 

 

View solution in original post