微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Opayo System.Security.Authentication.AuthenticationException: 根据验证程序,远程证书无效

如何解决Opayo System.Security.Authentication.AuthenticationException: 根据验证程序,远程证书无效

我们依靠 Opayo 使用他们的 API 进行付款。客户最近直接在其服务器上关闭了 TLS 1.0 和 1.1。

尝试付款时,我们会收到以下堆栈跟踪。我已经将Opayo证书安装到服务器上,但付款后仍然收到以下信息。

请问有人对如何解决这个问题有任何想法吗?

System.Net.WebException: The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel. ---> System.Security.Authentication.AuthenticationException: The remote certificate is invalid according to the validation procedure.
   at System.Net.Security.SslState.StartSendAuthResetSignal(ProtocolToken message,AsyncProtocolRequest asyncRequest,Exception exception)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message,AsyncProtocolRequest asyncRequest)
   at System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer,Int32 count,AsyncProtocolRequest asyncRequest)
   at System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer,AsyncProtocolRequest asyncRequest)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(ProtocolToken message,AsyncProtocolRequest asyncRequest)
   at System.Net.Security.SslState.ForceAuthentication(Boolean receiveFirst,Byte[] buffer,AsyncProtocolRequest asyncRequest)
   at System.Net.Security.SslState.ProcessAuthentication(LazyAsyncResult lazyResult)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext,ContextCallback callback,Object state,Boolean preserveSyncCtx)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext,Object state)
   at System.Net.Tlsstream.ProcessAuthentication(LazyAsyncResult result)
   at System.Net.Tlsstream.Write(Byte[] buffer,Int32 offset,Int32 size)
   at System.Net.PooledStream.Write(Byte[] buffer,Int32 size)
   at System.Net.ConnectStream.WriteHeaders(Boolean async)
   --- End of inner exception stack trace ---
   at System.Net.HttpWebRequest.GetRequestStream(TransportContext& context)
   at System.Net.HttpWebRequest.GetRequestStream()
   at PaymentCommon.httpPost.Post(String postdata,String url) in D:\Development\isys\Weighsoft\branches\5.378\Payment\PaymentCommon\httpPost.cs:line 44System.Security.Authentication.AuthenticationException: The remote certificate is invalid according to the validation procedure.
   at System.Net.Security.SslState.StartSendAuthResetSignal(ProtocolToken message,Int32 size)
   at System.Net.ConnectStream.WriteHeaders(Boolean async)
2021-07-23 16:59:22,952 INFO  - Application_End

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。