Pocket PC2003 WCF Authentication Issue
I have created a very simple WCF service that returns a datatime stamp from SQL Server to the client but I am having problems accessing the service from a Pocket PC 2003 Psion device.
I have no issues when accessing the service from a WinCe 5 device but when I deploy the client code to PPC2003 it generates a 407 Proxy Authentication exception.
I generated the proxy class with NetCFSvcUtil.exe and imported them into the project with no issues but cant access when running PPC2003.
<system.serviceModel>
<bindings />
<services>
<service behaviorConfiguration="TimeStampServiceBehavior"
name="JCB.QSmart.Mobile.DataService.ServerTime">
<clear />
<endpoint address="TimeStamp"
binding="basicHttpBinding"
name="TimeStamp"
contract="JCB.QSmart.Mobile.DataService.IServerTime"
listenUriMode="Explicit">
</endpoint>
<endpoint address="mex"
binding="mexHttpBinding"
name="mex"
contract="IMetadataExchange"
listenUriMode="Explicit"开发者_如何学编程>
</endpoint>
<host>
<baseAddresses>
<add baseAddress="http://xxx.xxx.xxx.xxx:8080/QSmartV2" />
</baseAddresses>
</host>
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="TimeStampServiceBehavior">
serviceMetadata httpGetEnabled="true"/>
<serviceDebug includeExceptionDetailInFaults="true"/>
</behavior>
</serviceBehaviors>
</behaviors>
</system.serviceModel>
Previously I have specified a proxy on the device and that worked but the proxy hardware has broken down and the application is not working. How else can I handle the authentication?
Phil
Http 407 is a network error refering to a proxy server on the network.
You need to set up proxy authentication in system.web see: http://www.mikebevers.be/blog/2009/06/wcf-http-407-proxy-authentication-required/
Since the WinCe is a windows OS it may be automaticaly authenticating itself to the proxy server.
精彩评论