简体   繁体   English

Azure WCF具有https wsdl URL,但终结点URL在http中

[英]Azure WCF has https wsdl url but endpoint url is in http

I'm trying to access Azure WCF in SPD. 我正在尝试在SPD中访问Azure WCF。 The http wsdl and endpoint works as expected, but the https wsdl cannot handle a https endpoint. http wsdl和端点可以正常工作,但是https wsdl无法处理https端点。 I opened up the wsdl and can see only a http endpoint. 我打开了wsdl,只能看到一个http端点。

Can anyone tell me how to have a https endpoint in wsdl soap:address location? 谁能告诉我如何在wsdl soap:address位置使用https端点?

using the https wsdl and http endpoint in SPD for ECT I can connect to the WCF service but it doesn't generate a tree view! 使用SPD中用于ECT的https wsdl和http端点,我可以连接到WCF服务,但它不会生成树视图!

At the end it generates an error: " The server was unable to process the request due to an internal error. For more information about the error, either turn on IncludeExptionDetailsFaults... blah blah blah " which I'm pretty sure that the config file has serviceDebug includeExceptionDetailInFaults="true" behavior already 最后,它生成一个错误:“ 服务器由于内部错误而无法处理该请求。有关该错误的更多信息,请打开IncludeExptionDetailsFaults ...等等等等。我很确定文件已经具有serviceDebug includeExceptionDetailInFaults =“ true”行为

config 配置

 <system.web>
    <customErrors mode="Off" />
    <compilation debug="true" targetFramework="4.0">
      <assemblies>
        <add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" />
      </assemblies>
    </compilation>
  </system.web>
  <system.serviceModel>
    <behaviors>
      <serviceBehaviors>
        <behavior>
          <serviceMetadata httpsGetEnabled="true" httpGetEnabled="true"/>
          <serviceDebug includeExceptionDetailInFaults="true" />
          <useRequestHeadersForMetadataAddress>
            <defaultPorts>
              <add scheme="http" port="80" />
              <add scheme="https" port="443" />
            </defaultPorts>
          </useRequestHeadersForMetadataAddress>
        </behavior>

      </serviceBehaviors>
    </behaviors>
    <serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
  </system.serviceModel>
  <system.webServer>
    <modules runAllManagedModulesForAllRequests="true" />
    <directoryBrowse enabled="true" />
  </system.webServer>

csdef csdef

<?xml version="1.0" encoding="utf-8"?>
<ServiceDefinition name="SPO_LOB" xmlns="http://schemas.microsoft.com/ServiceHosting/2008/10/ServiceDefinition" schemaVersion="2012-10.1.8">
  <WebRole name="SPO_LOB" vmsize="Small">
    <Sites>
      <Site name="Web">
        <Bindings>
          <Binding name="Endpoint1" endpointName="Endpoint1" />
          <Binding name="HttpsIn" endpointName="HttpsIn" />
        </Bindings>
      </Site>
    </Sites>
    <Certificates>
      <Certificate name="certsvc" storeLocation="LocalMachine"
          storeName="CA" />
    </Certificates>
    <Endpoints>
      <InputEndpoint name="Endpoint1" protocol="http" port="80" />
      <InputEndpoint name="HttpsIn" protocol="https" port="443" certificate="democloudsvc1" />
    </Endpoints>
    <Imports>
      <Import moduleName="Diagnostics" />
      <Import moduleName="RemoteAccess" />
      <Import moduleName="RemoteForwarder" />
    </Imports>
    <LocalResources>
      <LocalStorage name="SPO_LOB.svclog" sizeInMB="1000" cleanOnRoleRecycle="false" />
    </LocalResources>
  </WebRole>
</ServiceDefinition>

How is your mex endpoint defined in services section of web.config. 如何在web.config的services部分中定义您的mex端点。 it should be like this, 应该是这样的

Please note the binding has to be "mexHttpsBinding" - (https) 请注意,绑定必须是“ mexHttpsBinding”-(https)

added mex binding and endpoint now is in https 添加的mex绑定和端点现在在https中

<bindings>
      <basicHttpBinding>
        <binding name="SecureBasic" proxyAddress="http://localhost:80">
          <security mode="Transport">
            <transport clientCredentialType="None"/>
          </security>
        </binding>
      </basicHttpBinding>
    </bindings>
    <services>
      <service name="SPO_LOB.Service1" behaviorConfiguration="SVCbehavior">
        <host>
          <baseAddresses>
            <add baseAddress="https://localhost:443"/>
          </baseAddresses>
        </host>
        <endpoint binding="basicHttpBinding" bindingConfiguration="SecureBasic" name="basicHttpSecure" contract="SPO_LOB.IService1" />
        <endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
      </service>
    </services>
    <behaviors>

The remaining problem now is when I connect SPO BCS to the service it generates the error I mentioned above. 现在剩下的问题是,当我将SPO BCS连接到服务时,它会产生我上面提到的错误。 Even though IncludeExceptionDetailInFaults is set to true in config 即使IncludeExceptionDetailInFaults在配置中设置为true

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM