Share via


Default SPN

What happens if I don't specify an EndpointIdentity for an EndpointAddress? I'm supposed to provide one for the domain account of my service.

Well, it might work. If you don't explicitly specify an endpoint identity, then by default we'll use host/machinename to construct the service principal name identity (machinename is actually the name of the machine). That may be the SPN that the other side is expecting as well. If it's not, then you'll see an error message that includes this line telling you what went wrong.

This may be due to absent or incorrectly specified EndpointIdentity in the EndpointAddress used to create the channel.

The only ways to find out are to either look at the service configuration or just try and run it. If it works and you can call the service, then you're using the default. If you get the error message that I mentioned above, then you're not using the default. Nevertheless, it would help others if you included the SPN in your configuration even if you're using the default as it signals what might need to change if the client or service is relocated.

Next time: Multiple Web Site Bindings