code_junkie

IIS hosted WCF-service + Windows auth in IIS + TransportCredentialOnly/Windows auth in basicHttpBinding

Nov 11th, 2011
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.93 KB | None | 0 0
  1. <system.serviceModel>
  2. <bindings>
  3. <basicHttpBinding>
  4. <binding name="MyBinding">
  5. <security mode="TransportCredentialOnly">
  6. <transport clientCredentialType="Windows" />
  7. </security>
  8. </binding>
  9. </basicHttpBinding>
  10. </bindings>
  11. <services>
  12. <service name="Samples.ServiceFacadeService" behaviorConfiguration="ServiceFacadeServiceBehavior">
  13. <endpoint address="" binding="basicHttpBinding" bindingName="MyBinding"
  14. contract="Samples.IServiceFacadeService">
  15. </endpoint>
  16. </service>
  17. </services>
  18. <behaviors>
  19. <serviceBehaviors>
  20. <behavior name="ServiceFacadeServiceBehavior">
  21. <serviceDebug includeExceptionDetailInFaults="true"/>
  22. </behavior>
  23. </serviceBehaviors>
  24. </behaviors>
  25. </system.serviceModel>
  26.  
  27. <services>
  28. <!-- Note: the service name must match the configuration name for the service implementation. -->
  29. <service name="MyNamespace.MyServiceType" behaviorConfiguration="MyServiceTypeBehaviors" >
  30. <!-- Add the following endpoint. -->
  31. <!-- Note: your service must have an http base address to add this endpoint. -->
  32. <endpoint contract="IMetadataExchange" binding="mexHttpBinding" address="mex" />
  33. </service>
  34. </services>
  35.  
  36. <behaviors>
  37. <serviceBehaviors>
  38. <behavior name="MyServiceTypeBehaviors" >
  39. <!-- This disables it. -->
  40. <serviceMetadata httpGetEnabled="false" />
  41. </behavior>
  42. </serviceBehaviors>
  43. </behaviors>
  44.  
  45. <endpoint address="" binding="basicHttpBinding" bindingName="MyBinding"
  46. contract="Samples.IServiceFacadeService">
  47. </endpoint>
  48.  
  49. <endpoint address="" binding="basicHttpBinding" **bindingConfiguration**="MyBinding"
  50. contract="Samples.IServiceFacadeService">
  51. </endpoint>
Add Comment
Please, Sign In to add comment