A customer ran into this issue a while back a couple of times and I wanted to document it for others. The customer was using their SharePoint environment normally throughout the day when all of a sudden their Office Web Apps stopped working. As it turns out, the ultimate problem ended up being related to a timer job that wasn’t running properly, but we did find a work around while looking for that. Below is a description of the workaround.
If you’re seeing something along the lines as this in your Excel Web App (Server Error in ‘/x’ Application).
And if your event logs have something along the lines of this in them.
Where the details look like this below.
The Workaround
Then you can run the following PowerShell command (in an elevated PowerShell console) to correct the problem.
Update-SPWOPIProofKey
The above is just a work around, and the following is a description of the problem in more detail.
A quick look at the SPWOPI actions revealed this was a possible solution.
PS C:\Users\spadmin> get-help *spwopi*
Name Category Module Synopsis
—- ——– —— ——–
Get-SPWOPIBinding Cmdlet Microsoft.SharePoint.P… Applie…
New-SPWOPIBinding Cmdlet Microsoft.SharePoint.P… Applie…
Remove-SPWOPIBinding Cmdlet Microsoft.SharePoint.P… Applie…
Set-SPWOPIBinding Cmdlet Microsoft.SharePoint.P… Applie…
Get-SPWOPIZone Cmdlet Microsoft.SharePoint.P… Applie…
Set-SPWOPIZone Cmdlet Microsoft.SharePoint.P… Applie…
Get-SPWOPISuppressionSetting Cmdlet Microsoft.SharePoint.P… Applie…
New-SPWOPISuppressionSetting Cmdlet Microsoft.SharePoint.P… Applie…
Remove-SPWOPISuppressionSetting Cmdlet Microsoft.SharePoint.P… Applie…
Update-SPWOPIProofKey Cmdlet Microsoft.SharePoint.P… Applie…
Simply running this command on the PowerShell command line (on the SP server) resolved the issue with previews not being generated at the client (note the OWA farm looked OK on the OWA server).
Update-SPWOPIProofKey Detailed Description
The Update-SPWOPIProofKey cmdlet updates the public key that is used to connect to the WOPI application (which could be a server that runs Office Web Apps Server) on the current SharePoint farm where this cmdlet is run. You may want to use this cmdlet if the keys become unsynchronized between the SharePoint farm and the WOPI application. If the keys are unsynchronized, documents may not open in the browser and messages such as “Invalid Proof Signature for file…” or “Invalid Proof Signature for folder…” are found in the Unified Logging System (ULS) logs.
Here’s what was Really Happening at the Customer’s Site:
The root of the issue was as follows.
This timer job, which was scheduled to run every half hour, hadn’t run in months. In our case, the entirely server was screwed up (we eventually replaced the server, and rebuilt the AppFabric Cache on a new set of servers, and then the SharePoint Timer service started running properly again, including this job).
The ProofKeys change regularly, and as such, can be become out of date between SharePoint and the Office Web Apps server. Normally, this timer job (properly running on schedule) would be sufficient to automatically obtain the new keys.
ProofKeys Detailed Description
ProofKeys change regularly on the Office Web Apps server. Use Update-SPWOPIProofKey to update them on SharePoint. Alternatively, change the timer job schedule with:
set-SPTimerJob “job-rerun-discovery” -schedule “<your desired schedule>”
Hi!
I have the same error on outlook web app. This solution is for sharepoint … could you help me with a solution for exchange?
best regards
chris
I’m not terribly familiar with exchange, but perhaps if you could provide some additional details, I could investigate further.
We ran in a similar issue on our SharePoint farm.
WOPI Discovery Synchronization timer job would fail on one of the 4 servers with the following error:
The validation of proof token is failed and possible cause is that the issuer of the proof token is not trusted or proof token has invalid claims in it.
Running the above mentioned Update-SPWOPIProofKey solved the issue!
However in our case we also needed to stop the SPTimer service on the problematic server before running the command. After that the issue went away.
Thank you for your post!
We ran in a similar issue on out production SharePoint farm.
WOPI Discovery Synchronization timer job would fail on one of the 4 servers with the following error:
The validation of proof token is failed and possible cause is that the issuer of the proof token is not trusted or proof token has invalid claims in it.
Running the above mentioned Update-SPWOPIProofKey solved the issue!
However in our case we also needed to stop the SPTimer service on the problematic server before running the command. After that the issue went away.
Thank you for your post!
I am using Excel Web Apps (EWA) for a custom export to excel feature using angularjs. The export works fine in Chrome but fails sometimes in Internet Explorer with “Server Error in ‘/x’ Application.” error message.
Geart, It Works!
Thanks a lot Colin.
in my case it was because the net.pipe listener adapter was stopped (in services console)
Thanks! I would have never found the issue….