FIX: Starting a new approval fails 90 days after installation
This Zetadocs technical note applies to:
- Zetadocs Payables Approval
- SharePoint Online
When navigating to the start approval screen for a document in Zetadocs Payables Approvals one of the following error messages is received:
- Failed to get related documents. Authentication failed. Please check that the SharePoint credentials in your Zetadocs Approval Connector are correct.
- Failed to get approval.
- Failed to get approval. Authentication failed. Please check that the SharePoint credentials in your Zetadocs Approval Connector are correct.
The ZetadocsApprovalConnector.log can be found in %temp%\Zetadocs\ZetadocsApprovalConnector.log, where %temp% is the temporary directory of the user that Zetadocs Connector is running as. When ZetadocsApprovalConnector.log is inspected there will be an entry.
Authentication failure accessing site: “http://yoursite.onmicrosoft.com. Please check your SharePoint credentials in the Zetadocs Approval Connector.
Where yoursite is the name of your SharePoint site.
The issue described above can happen when the password for the Office 365 account utilized by the Zetadocs Approvals Connector expires. By default the password for an Office 365 account will expire every 90 days.
The Zetadocs Approvals Connector has to connect to your SharePoint site in Office 365 to retrieve the list of related documents. The credentials for the Office 365 account that will be used for this are stored in Zetadocs.Approval.Connector.exe.config, which is usually located in your connector installation folder, usually C:\Program Files (x86)\Zetadocs Approval Connector.
The Office 365 account password can be set to never expire by using a Windows PowerShell command. To do this please follow the steps below:
- Download Windows Azure AD Module for Windows PowerShell (including Microsoft Online Services Sign-In Assistant) from here.
- Run the Microsoft Online Services Sign-In Assistant installer.
- Accept the License Agreement, then select Install. Once the setup program is complete select Finish.
- Run the Azure AD Module for Windows PowerShell installer.
- Click Next and accept the license agreement.
- Choose the install location and click Next.
- Click Install and select Finish once the setup program has completed.
- Run Microsoft Online Services Module for Windows Powershell.
- Import the following cmdlets by pasting them into Powershell.
- Run the command: import-module MSOnline.
- Enter the command: Connect-MsolService. This will attempt to connect to the service, a dialog will appear requesting your login credentials.
- Add the Administrator account credentials.
- Next paste, into Powershell the command: Get-MSOLUser | Select UserPrincipalName, PasswordNeverExpires. This will display a list of User Principal Names.
- Identify the User Principal Name of the account that the Zetadocs Approvals Connector uses to connect to SharePoint and use it to replace < user principal name> in the following command,
Set-MsolUser –UserPrincipalName < user principal name> -PasswordNeverExpires $true.
e.g. Set-MsolUser -UserPrincipalName Zetafax@mycompany.onmicrosoft.com -PasswordNeverExpires $true.
- Paste the resultant command into Powershell, including the specific user principal name.
- This sets the password on the mailbox to never expire.
This has been identified by Equisys as a problem with the software versions given above.
Last updated: 5th December 2013 (SB/MW)
Keywords: Payables Approval, password, 365, Authentication, Failed, SharePoint, Credentials, Zetadocs, Connector