我设计了一个WCF服务,用于Iphone
和Android
的新用户身份验证。最初我使用basciHttpBinding
并且我的服务对Iphone工作正常,但是15-20天后我改变了配置,现在我正在使用wsHttpBinding
。现在,我无法使用Iphone
从wsHttpBinding
拨打我的服务,但它适用于Android
。我听说wsHttpBinding
对Iphone
不起作用。任何人都可以建议我在我的web.config中应该使用什么配置来为Iphone
工作。
的Web.Config
<?xml version="1.0"?>
<configuration>
<configSections>
<sectionGroup name="spring">
<section name="context" type="Spring.Context.Support.ContextHandler, Spring.Core"/>
<!--<section name="context" type="Spring.Context.Support.WebContextHandler, Spring.Web"/>-->
<section name="parsers" type="Spring.Context.Support.NamespaceParsersSectionHandler, Spring.Core"/>
</sectionGroup>
</configSections>
<spring>
<parsers>
<parser type="Spring.Data.Config.DatabaseNamespaceParser, Spring.Data"/>
<parser type="Spring.Transaction.Config.TxNamespaceParser, Spring.Data"/>
</parsers>
<context>
<!--<resource uri="config://spring/objects"/>-->
<!--<resource uri="assembly://TA.Service/TA.Service.Config/DynamicConnection.xml"/>-->
<resource uri="~/DynamicConnection.xml"/>
<resource uri="assembly://TA.Service/TA.Service.Config/Dao.xml"/>
<!--<resource uri="~/Dao.xml"/>-->
<!--<resource uri="~/Config/Web.xml"/>-->
<!--<resource uri="assembly://CB.Service/CB.Service/Services.xml"/>-->
</context>
</spring>
<appSettings>
<add key="Spring.Data.NHibernate.Support.OpenSessionInViewModule.SessionFactoryObjectName" value="NHibernateSessionFactory"/>
</appSettings>
<system.web>
<compilation debug="true" targetFramework="4.0" />
</system.web>
<system.serviceModel>
<behaviors>
<endpointBehaviors>
<behavior name="myBehavior">
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="serviceBehaviour">
<!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
<serviceMetadata httpGetEnabled="true"/>
<!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information -->
<serviceDebug includeExceptionDetailInFaults="false"/>
</behavior>
</serviceBehaviors>
</behaviors>
<bindings>
<wsHttpBinding>
<binding name="NewBinding0">
<reliableSession enabled="true" />
<security mode="None" />
</binding>
</wsHttpBinding>
</bindings>
<services>
<service name="TA.Service.Service1" behaviorConfiguration="serviceBehaviour">
<endpoint address="" binding="wsHttpBinding" behaviorConfiguration="myBehavior"
bindingConfiguration="NewBinding0" name="testendpoint" contract="TA.Service.IService1" />
</service>
</services>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true"/>
</system.serviceModel>
<system.webServer>
<modules runAllManagedModulesForAllRequests="true"/>
</system.webServer>
</configuration>
答案 0 :(得分:0)
尝试使用SoapUI测试您的服务,它在SoapUI或任何其他肥皂测试工具上提供正确的结果,然后它在您的IPhone客户端开发站点的客户端出现问题。
您可以从以下网址获取免费的肥皂ui。 http://www.soapui.org/
谢谢,
拉夫