【发布时间】:2013-10-28 23:06:48
【问题描述】:
我们的证书即将到期,我们认为更改它以及使用它的服务就像更新证书并使用证书的新指纹更新服务一样简单,但事实并非如此。
现在,这段代码是继承的,不是我写的,所以我想弄清楚。它就在这里中断:
var issuedToken = channel.Issue(rst) as GenericXmlSecurityToken;
这个东西应该击中的所有服务也都用新证书更新了。任何指针都非常感谢!
抛出的异常:
System.ServiceModel.CommunicationException 被捕获 H结果=-2146233087 消息=接收对 https://***ipsts/Service.svc/IWSTrust13 的 HTTP 响应时出错。这可能是由于服务端点绑定未使用 HTTP 协议。这也可能是由于服务器中止了 HTTP 请求上下文(可能是由于服务关闭)。有关更多详细信息,请参阅服务器日志。 源=mscorlib 堆栈跟踪: 服务器堆栈跟踪: 在 System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException(WebException webException,HttpWebRequest 请求,HttpAbortReason abortReason) 在 System.ServiceModel.Channels.HttpChannelFactory
1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout) at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout) at System.ServiceModel.Channels.SecurityChannelFactory1.SecurityRequestChannel.Request(消息消息,TimeSpan 超时) 在 System.ServiceModel.Channels.ServiceChannel.Call(字符串操作,布尔单向,ProxyOperationRuntime 操作,Object[] 输入,Object[] 输出,TimeSpan 超时) 在 System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage 方法调用,ProxyOperationRuntime 操作) 在 System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage 消息) 在 [0] 处重新抛出异常: 在 System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg,IMessage retMsg) 在 System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData,Int32 类型) 在 Microsoft.IdentityModel.Protocols.WSTrust.IWSTrustContract.Issue(消息消息) 在 Microsoft.IdentityModel.Protocols.WSTrust.WSTrustChannel.Issue(RequestSecurityToken rst,RequestSecurityTokenResponse& rstr) 在 Microsoft.IdentityModel.Protocols.WSTrust.WSTrustChannel.Issue(RequestSecurityToken rst) 在 C:\Development\Mobile Service\Mobile Service\Code\ECNSecurityTokenService.cs:line 59 中的 Mobile_Service.Code.ECNSecurityTokenService.GetClaimsPrincipalWithUserName(String userName, String password) 内部异常:System.Net.WebException H结果=-2146233079 Message=底层连接已关闭:接收时发生意外错误。 源=系统 堆栈跟踪: 在 System.Net.HttpWebRequest.GetResponse() 在 System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan 超时) 内部异常:System.IO.IOException H结果=-2146232800 消息=无法从传输连接读取数据:现有连接被远程主机强行关闭。 源=系统 堆栈跟踪: 在 System.Net.Sockets.NetworkStream.Read(字节 [] 缓冲区,Int32 偏移量,Int32 大小) 在 System.Net.FixedSizeReader.ReadPacket(字节 [] 缓冲区,Int32 偏移量,Int32 计数) 在 System.Net.Security._SslStream.StartFrameHeader(字节 [] 缓冲区,Int32 偏移量,Int32 计数,AsyncProtocolRequest asyncRequest) 在 System.Net.Security._SslStream.StartReading(字节 [] 缓冲区,Int32 偏移量,Int32 计数,AsyncProtocolRequest asyncRequest) 在 System.Net.Security._SslStream.ProcessRead(字节 [] 缓冲区,Int32 偏移量,Int32 计数,AsyncProtocolRequest asyncRequest) 在 System.Net.TlsStream.Read(字节 [] 缓冲区,Int32 偏移量,Int32 大小) 在 System.Net.PooledStream.Read(字节 [] 缓冲区,Int32 偏移量,Int32 大小) 在 System.Net.Connection.SyncRead(HttpWebRequest 请求,布尔 userRetrievedStream,布尔 probeRead) 内部异常:System.Net.Sockets.SocketException H结果=-2147467259 Message=远程主机强制关闭现有连接 源=系统 错误代码=10054 NativeErrorCode=10054 堆栈跟踪: 在 System.Net.Sockets.NetworkStream.Read(字节 [] 缓冲区,Int32 偏移量,Int32 大小) 内部异常:
【问题讨论】: