我们最近从HTTP转到HTTPS,我们的网络服务停止了工作,我一直在尝试多种方法让它们再次运行。
在我看来,他们已经启动并且正在运行但是由于某种原因所有对他们的呼叫都被阻止了......
我得到的错误
Mixed Content: The page X at 'https://website/project/page.aspx' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://website:123/WebService/ProjectTreeService.svc/Clone'. This request has been blocked; the content must be served over HTTPS.
我的web.config文件设置如下:
<system.serviceModel>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true"/>
<bindings>
<webHttpBinding>
<binding name="ProjectTreeService_webHttpBinding">
<security mode="Transport" />
</binding>
</webHttpBinding>
</bindings>
<services>
<service name="PROJ.IProjectTreeService" behaviorConfiguration="ProjectTreeService_ServiceBehaviour">
<endpoint address="" behaviorConfiguration="webHttp" binding="webHttpBinding" bindingConfiguration="ProjectTreeService_webHttpBinding" contract="PROJ.IProjectTreeService"/>
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
</service>
</services>
<behaviors>
<endpointBehaviors>
<behavior name="webHttp">
<webHttp/>
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="ProjectTreeService_ServiceBehaviour">
<serviceMetadata httpGetEnabled="true" httpsGetEnabled="true"/>
<serviceDebug includeExceptionDetailInFaults="true"/>
</behavior>
</serviceBehaviors>
</behaviors>
我错过了哪些想法?
编辑:
我不知道是否有任何帮助,但当我浏览(https://website:123/WebService/ProjectTreeService.svc)服务时,我可以看到set_path函数与http
一起使用 PROJ.Service.Internal.IProjectTreeService.set_path("http://website:123/WebService/ProjectTreeService.svc");