我想爲我的Silverlight應用程序使用當前的Windows用戶。使用任何其他應用程序,我可以使用WindowsIdentity
,但似乎我需要使用WCF與ServiceSecurityContext.Current
。我的問題是.Current
出現爲null
。在WCF/Silverlight中使用ServiceSecurityContext.Current 4
顯然這是因爲我使用的傳輸模式。我的問題是,Silverlight不能使用TransportWithMessageCredential
顯然沒有它想使用Https。
所以我嘗試使用TransportWithMessageCredential
和我的服務開始說它期待Https,但接受Http。
我在網上看了一圈,似乎我需要使用wsHttpBinding(不適用於Silverlight)或某種形式的訪問策略使用Http(看起來不起作用)。
當然有更簡單的方法來做到這一點?
有沒有可能這樣做aspNetCompatibilityEnabled =「true」 – TheWommies 2013-07-30 22:50:57