WCF service SecurityNegotiationException

后端 未结 2 678
花落未央
花落未央 2021-01-05 05:17

I am running a simple service on my server with WCF; the service is hosted in WebDev.WebServer.exe (local).

When I call the Service local I get the following excepti

相关标签:
2条回答
  • 2021-01-05 05:49

    The problem was in server, I put mode="Message" and works well. thanks.

    <security mode="None">  
    
    <transport clientCredentialType="Windows" proxyCredentialType="None" realm="" />  
    
    <message clientCredentialType="Windows" negotiateServiceCredential="true" establishSecurityContext="true" />  
    
    </security> 
    
    0 讨论(0)
  • 2021-01-05 05:55

    WCF is very powerful, but can be a config nightmare. Here are some potential leads:

    • Turn on the WCF trace logs, rerun your scenario and then check the logs with SvcTraceViewer.exe
    • Figure out how far the messaging gets...
      • i.e. does the client form the request and send it to the server who rejects it (i.e. in the lower WCF layers before your own service code is hit);
      • or does the request get stopped in its tracks before that.. the client never even sending the request
    • http://schemas.xmlsoap.org/ws/2005/02/trust/RST/Issue is a WS-Trust token-related message, so there'll be something going on with authentication
      • the error's implying that there's a config mismatch, but using SvcUtil should have them lined up like you said
    • The client binding has the server at "http://localhost:1634/UsuarioContexto.svc"
      • I don't see that port specified in the service config... is the service listening on that port?
      • if you open a browser and aim it at that URL, do you get a default service page?
    0 讨论(0)
提交回复
热议问题