求救:更新服务引用失败
silverlight服务引用更新失败,提示如下:
下载https://192.168.10.15/ESA_WEB_MER.svc时出错
请求因HTTP状态403失败 Forbidden
元数据包含无法解析的引用
使用客户端身份验证方案Anonymous禁止HTTP请求
远程服务器返回错误(403)已禁止
两台机器一样的设置,为什么会有不同的结果?这是什么原因,大家指点一下!
[解决办法]
你检查确认下你的服务是否有错误,实体类是否可以被序列化,等。
[解决办法]
在Endpoint中要使用安全传输(Transport security)
参考:
<system.serviceModel> <serviceHostingEnvironment aspNetCompatibilityEnabled="true" /> <services> <service name="My.Services.Web.ServiceImpl" behaviorConfiguration="ServiceBehaviors"> <endpoint address="" binding="basicHttpBinding" contract="RMy.Services.Web.IService" /> <endpoint address="" binding="basicHttpBinding" bindingConfiguration="SecureTransport" contract="My.Services.Web.IService" /> </service> </services> <bindings> <basicHttpBinding> <binding name="SecureTransport"> <security mode="Transport"> <transport clientCredentialType="None"/> </security> </binding> </basicHttpBinding> </bindings> <behaviors> <serviceBehaviors> <behavior name="ServiceBehaviors" > <serviceMetadata httpGetEnabled="true" /> <serviceDebug includeExceptionDetailInFaults="true" httpHelpPageEnabled="true" httpsHelpPageEnabled="true"/> </behavior> </serviceBehaviors> </behaviors> </system.serviceModel>