English 中文(简体)
通过基本标准,在《世界家庭状况》中进行习俗认证 HttpBelle
原标题:Custom authentication in WCF through basicHttpBinding

我的妇联工作。 我有以下组合:

<bindings>
  <basicHttpBinding>
      <binding name="HttpStreaming" maxReceivedMessageSize="65536000" closeTimeout="00:05:00" bypassProxyOnLocal="true" openTimeout="00:05:00" receiveTimeout="00:30:00" sendTimeout="00:30:00" transferMode="Streamed" messageEncoding="Mtom">
        <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="65536000" maxBytesPerRead="4096" maxNameTableCharCount="16384" />
        <security mode="None">
          <transport clientCredentialType="None" proxyCredentialType="None" realm="" />
        </security>
      </binding>
  </basicHttpBinding>
</bindings>

<behaviors>
  <serviceBehaviors>
    <behavior name="CifsManager.CifsManagerServiceBehavior">
      <serviceMetadata httpGetEnabled="true" />
      <serviceDebug includeExceptionDetailInFaults="true" />
    </behavior>
  </serviceBehaviors>
</behaviors>

<services>
  <service behaviorConfiguration="CifsManager.CifsManagerServiceBehavior" name="CifsManager.CifsManagerService">
    <endpoint address="" binding="basicHttpBinding" bindingConfiguration="HttpStreaming" contract="CifsManager.ICifsManagerService"></endpoint>
  </service>
</services>

我制作了代理班,称为 ServiceClient

var service = new ServiceClient();
service.ClientCredentials.UserName.UserName = "111";
service.ClientCredentials.UserName.Password = "111";
service.bufferSize = int.Parse(ConfigurationManager.AppSettings["BufferSize"]);
var file= service.GetFile();

Here I found the articles where it is described how to solve my problem throught the wsHttpBinding, but using it I get the server error. Could I create the authentication using the basicHttpBinding or I need the wsHttpBinding and how should I do it?

最佳回答

我只是想把所有这些都归为一种答案,这样,它就在一个地方,更容易找到,而不是在评论中传播。 采用<条码>BasicHttpBled,意味着你的全权证书将用简单文字通过,意思是,可以在没有麻烦的情况下沿途拦截。 您可以通过使用<密码>WsHttpBled来避免这一问题,该编码允许你使用三种不同的安全类型之一:Transport,Message,或TransportWithMessage Credential 。 http://msdn.microsoft.com/en-us/library/ms731925.aspx” rel=“nofollow noreferer”>here。 但铭记,如果你有的话,就得有一份表格的证明。

问题简要讨论了一些其他全球合作框架安全备选办法。 如果你在使用<条码>BasicHttpBled后死去,并通过电线上的全权证书,你至少可以考虑在这样做之前掩盖这些证件,或许是盐类或类似的沙1。 如果你不希望利用像住房伙伴这样的现有解决办法,那么就会出现。 NET 你们的会员们不得不自行表示,你们想背弃和 forth。

问题回答

暂无回答




相关问题
ajax login using httpRequest?

I am trying to develop my login script to give feedback to the user if the login is valid or not. Basically if it isn t correct a div box will show saying its wrong, if its correct it will show its ...

Remotely authenticating client Windows user on demand

Suppose I am writing a server for a particular network protocol. If I know that the client is running on a Windows machine, is it possible for my server to authenticate the Windows user that owns the ...

Role/Permission based forms authorizing/authentication?

While looking into forms authorizing/authentication, I found that it is possible to do role based authorizing by adding an array of roles to a FormsAuthenticationTicket. That way I can write User....

热门标签