Neil Walker
Neil Walker

Reputation: 6858

wcf web service identity servicePrincipalName explanation required

I have a web service that uses windows integrated authentication, and it works. But only after much trial and error it only finally worked with my config file endpoint section having an identity as follows:

<identity>
      <servicePrincipalName value="host/servername" />
</identity>

Where 'servername' is the name of the IIS server hosting the webservice.

If I missed it out, IIS refused it (did not even get to the end point) with 'authentication error'.

However, when I recently needed to run a program on the same server as the web service this then failed with the same error and it worked only if I completely removed the identity or changed it to 'host/localhost'.

Can somebody explain why this is because I really don't understand what the servicePrincipalName/identity is really doing other than just working.

thanks.

Upvotes: 0

Views: 585

Answers (1)

S.N
S.N

Reputation: 5140

The name of the user you wish the service to use (execute under) are placed as value for ServicePrincipalName.

You can have much simpler reference here.

Upvotes: 1

Related Questions