Configuration Property Value is Not Valid for Service Certificate

What you don't see can hurt you...

Here is an error I got having to do with a certificate. Each certificate has a thumbprint which must match the thumbprint specified in the configuration file.

When I first got the error shown below, I thought it was because I didn't have the certificate installed locally (though I had the file). If you have the same error, that may be the case for you. If that is the case, you can follow the below steps to install it locally:

  • Launch mmc.exe from the start menu
  • Select File -> Add/remove snap-in
  • A screen will pop up. Select certificates from the left hand column.
  • Click the "Add" button to move it to the right hand column.
  • When you click the "Add" button, a new screen will pop up. Select the "Computer account" radio button.
  • Click "Next."
  • Select the "Local computer" radio button.
  • Click "Finish."
  • Click "OK" in the "Add or Remove Snap-ins" diaglog box.
  • Drop down the certificates menu.
  • Drop down the "Personal" folder.
  • Right click on "Certificates" -> All tasks -> Import
  • Walk through the wizard, accepting all defaults.

If you're missing the certificate locally, that should install it. Give your solution another shot and see if the error goes away.

As it turned out in my case, however, I had the certificate installed locally. After comparing thumbprints numerous times, I was confident the thumbprint on the certificate and the thumbprint in the config file were identical matches. I even copied the value from the config file into Notepad++ to show all hidden characters to see if anything showed up. Nothing.

A coworker finally discovered the issue after very carefully watching the cursor as he clicked through the thumbprint value. His cursor would be sitting in front of the first character. If he pressed the right arrow once, it didn't move. If he pressed it again, it moved passed the first character. Though Notepad++ couldn't see it, there was a hidden character at the beginning of the thumbprint value in the config file. Culprit found.

A simple backspace keystroke when on the hidden character and we were in business.


portrait title

About Scott

I am a software engineer from Bozeman, MT enjoying the slightly warmer climate of Colorado. I think code can change lives. I think lives are worth changing. I write code.

You can find me on Twitter, LinkedIn, , and Github.