I am working on WCF in following scenario Authenticating and Authorizing Users by Using the SQL Membership Provider and the SQL Role Provider Host : Asp.NET website Client : Console application.
I am using WsHttpBinding over HTTPS communications (at my local),
I am getting following exception while communicating
Unhandled Exception: System.ServiceModel.Security.MessageSecurityException: An u
nsecured or incorrectly secured fault was received from the other party. See the
inner FaultException for the fault code and detail. ---> System.ServiceModel.Fa
ultException: At least one security token in the message could not be validated.
--- End of inner exception stack trace ---
Server stack trace:
at System.ServiceModel.Channels.SecurityChannelFactory`1.SecurityRequestChann
el.ProcessReply(Message reply, SecurityProtocolCorrelationState correlationState
, TimeSpan timeout)
at System.ServiceModel.Channels.SecurityChannelFactory`1.SecurityRequestChann
el.Request(Message message, TimeSpan timeout)
at System.ServiceModel.Security.SecuritySessionSecurityTokenProvider.DoOperat
ion(SecuritySessionOperation operation, EndpointAddress target, Uri via, Securit
yToken currentToken, TimeSpan timeout)
at System.ServiceModel.Security.SecuritySessionSecurityTokenProvider.GetToken
Core(TimeSpan timeout)
at System.IdentityModel.Selectors.SecurityTokenProvider.GetToken(TimeSpan tim
eout)
at System.ServiceModel.Security.SecuritySessionClientSettings`1.ClientSecurit
ySessionChannel.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.OnOpen(TimeSpan timeout)
at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
at System.ServiceModel.Channels.ServiceChannel.CallOpenOnce.System.ServiceMod
el.Channels.ServiceChannel.ICallOnce.Call(ServiceChannel channel, TimeSpan timeo
ut)
at System.ServiceModel.Channels.ServiceChannel.CallOnceManager.CallOnce(TimeS
pan timeout, CallOnceManager cascade)
at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean on
eway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan tim
eout)
at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCall
Message methodCall, ProxyOperationRuntime operation)
at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)
Exception rethrown at [0]:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req
Msg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgDa
ta, Int32 type)
at ProductsClient.ProductsService.IProductsService.ListProducts()
at ProductsClient.ProductsService.ProductsServiceClient.ListProducts() in D:\
Visual Studio\WCF\PracticeInNotes\51Web_HttpHost_SQLAuth_SQLAutr_TrSec\Web_HttpH
st_SQLAuth_SQLAutr_TrSec\ProductsClient\ProductsService.cs:line 285
at ProductsClient.Program.Main(String[] args) in D:\Visual Studio\WCF\Practic
eInNotes\51Web_HttpHost_SQLAuth_SQLAutr_TrSec\Web_HttpHst_SQLAuth_SQLAutr_TrSec\
ProductsClient\Program.cs:line 45
Press any key to continue . . .
Aucun commentaire:
Enregistrer un commentaire