Jim's Blog Ramblings about novels, comics, programming, and other geek topics

2Sep/101

WCF Error: An error occurred when verifying security for the message

Google AdSense

This is one of the trickiest and most obscure errors that I have encountered. I’ve seen this happen twice over the last year or so. The first time, I tried everything and eventually, after spending nearly a day researching and debugging, found the answer.


Symptoms

You receive a Microsoft Windows Communication Foundation (WCF) error stating:

An error occurred when verifying security for the message.

 

Cause and Verification

 

First, check the system time of both the server and the client systems. Once you’ve logged into the servers, just type “time” (and press enter a second time) or look at the clock displayed on the taskbar.

If the times are out of sync by more than a few minutes, then this is probably the problem. To sync times see the solution below. If your clocks are in sync, then it’s another solution.

 

Resolution

To sync clocks, follow the below steps:

  1. Open a command prompt.
  2. Enter the command “w32tm /resync”

If there has been any network changes, then you may also use “w32tm /resync /rediscover”. That additional argument will tell the server to find a new time synchronization server.

 

References:

James Welch

James Welch is a software engineer in Vermont working for a large information technology company and specializing in .NET. Additionally, he holds a Master’s Degree in Software Engineering and a Bachelor of Science Degree in Computer Science. Jim also enjoys local craft beer, comic books, and science-fiction and fantasy novels, games, and movies.

Twitter Google+ 

Comments (1) Trackbacks (0)
  1. Made my day! Thanks!


Leave a Reply

No trackbacks yet.