0
我爲一的wsHttpBinding綁定配置定義爲,即使它不在服務的app.config指定傳輸的安全性:客戶端的app.config創建
<wsHttpBinding>
<binding name="CustomAuthentication">
<security mode="Message">
<!-- Change to Message-->
<message clientCredentialType="UserName"/>
<!-- Change to UserName -->
</security>
</binding>
</wsHttpBinding>
當使用SvcUtil工具生成我我的代理代碼,看看它生成客戶端的app.config中,我看到這個在安全部分:
<security mode="Message">
<transport clientCredentialType="Windows" proxyCredentialType="None" realm="" />
<message clientCredentialType="UserName"
negotiateServiceCredential="true"
algorithmSuite="Default" />
</security>
我沒有在我的服務配置指定的運輸保障,爲啥它創建傳輸節點與clientCredentialType =「窗口」 。這是否由設計決定,並且這很重要?我觀看了一個我的Michele Leroux Bustamante的視頻,她說你不能使用傳輸和消息,它會忽略其中的一個,因此,如果你指定了兩個都沒關係。我只是想知道爲什麼它創建它在客戶端app.config