This known issue caused by the recent security update that was installed on your SharePoint server 2016.
SharePoint workflows can’t be published because the unauthorized type is blocked after patching. The issue generates event tag “c42q0” in SharePoint ULS logs.
Firstly, I suggest you check ULS logs to see if has the "c42q0" event tag.
If so, to work around this issue, register the safe types in the Web.config file. You can look for event tag "c42q0" in ULS logs to find the blocked type. If the type and assembly are safe, add the type to the authorized list in the Web.config file.
For example:
<System.Workflow.ComponentModel.WorkflowCompiler>
<authorizedTypes>
<targetFx version="v4.0">
<authorizedType Assembly="Microsoft.SharePoint.WorkflowActions, Version=16.0.0.0, Culture=neutral, PublicKeyToken=null" Namespace="Microsoft.SharePoint.WorkflowActions.WithKey" TypeName="*" Authorized="True" />
</targetFx>
</authorizedTypes>
Reference:
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.