views:

49

answers:

2

Hi

I have a simple WCF service hosting on IIS6 on a server on the network.

When I use the following binding on a server in my network I got 404, if just made clientCredentialType None, it works, also it works on my machine, why Windows authentication fails on server, 404 actually means it cannot even see the endpoint, if it is a proxy problem how to fix that.

<basicHttpBinding>
    <binding name="HttpWindowsAuthentication" 
             maxReceivedMessageSize="1048576" bypassProxyOnLocal="true" 
             useDefaultWebProxy="false">
        <security mode="TransportCredentialOnly">
            <transport clientCredentialType="Windows" proxyCredentialType="None"/>
        </security>
     </binding>
</basicHttpBinding>

thanks

A: 

It is probably security related, since it works when you change the clientCredentialType.

That you get 404, is to improve security, the system is saying "I cannot find the file", instead of saying "Yes there is a file with that name but you are not allowed to look at it".

It looks like the user that is making the wcf call does not have access to the svc file, but the user running the asp.net process does. The user that is running the asp.net process is used for anonymous clients.

The above assumes default settings.

Shiraz Bhaiji
HiIt is security problem, solved by 1- I simply did not specify a windows authentication in WCF
Costa
A: 

Hi

Thanks Shiraz

It is security problem, I simply did not specify Windows authentication in WCF configuration file, also mexHttpBinding did not work with windows authentication!!.

Some Clients on network was using impersonation by mistake, they got 401, so I clear the option from IIS see http://msdn.microsoft.com/en-us/library/aa292118%28VS.71%29.aspx

Costa