开发者

Windows Phone 7 Application + WCF + SSL + Username Authentication

开发者 https://www.devze.com 2022-12-25 16:32 出处:网络
I have developed a test service with WCF, which I try to consume from a Windows Phone 7 Application, however when calling a method from the service I get a weird exception:

I have developed a test service with WCF, which I try to consume from a Windows Phone 7 Application, however when calling a method from the service I get a weird exception:

There was no endpoint listening at https://server/Service.svc that could accept the message. This is often caused by an incorrect address or SOAP action.

The WCF service uses a custom binding with UserNameOverTransport authentication and SSL. For the authorization I am using an implementation of the UserNamePasswordValidator. If I try to consume the service from a console or si开发者_JAVA技巧lverlight application (cross domain policy is enabled) - it works fine (authorization as well). And the most weird thing is that the ServiceReferences.ClientConfig file generated for the WP7 App is exactly the same as the config file generated for the silverlight application.

I have no idea what is wrong with my service...


First suggestion: don't assume it's your service at fault. The WM7 SDK is far from bug-free. I suggest writing a conventional WPF, WinForms or Console client to test your service to be sure it's not a WM7 problem.


By the date of this question, it seems to me you were testing this in the emulator and the emulator doesn't support HTTPS.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号