1

SQL Server からクライアントにデータタイム スタンプを返す非常に単純な WCF サービスを作成しましたが、Pocket PC 2003 Psion デバイスからサービスにアクセスする際に問題が発生しています。

WinCe 5 デバイスからサービスにアクセスするときは問題ありませんが、クライアント コードを PPC2003 に展開すると、407 プロキシ認証例外が生成されます。

NetCFSvcUtil.exe でプロキシ クラスを生成し、問題なくプロジェクトにインポートしましたが、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>

以前、デバイスでプロキシを指定して動作しましたが、プロキシ ハードウェアが故障しており、アプリケーションが動作していません。他にどのように認証を処理できますか?

フィル

4

1 に答える 1

1

Http 407 は、ネットワーク上のプロキシ サーバーに関するネットワーク エラーです。

system.web でプロキシ認証を設定する必要があります: http://www.mikebevers.be/blog/2009/06/wcf-http-407-proxy-authentication-required/を参照してください。

WinCe は Windows OS であるため、プロキシ サーバーに対して自動的に認証を行っている可能性があります。

于 2011-06-01T19:12:12.923 に答える