none
Facing issue while uploading a file in dot net ,SSL is configured correctly. RRS feed

  • Question

  • I have written the code in dot net to download and upload,it is working in Dev and Prod as well ,Same dll's have deployed in another new server and SSL certificate configured by admin guys.

    While uploading i am facing the issue as below.

    An operation failed because the following certificate has validation errors:\n\nSubject Name: CN=emspeed.test.slb.com, OU=Services, O=Schlumberger, L=Houston, S=Texas, C=US\nIssuer Name: CN=Schlumberger Issuing CA2, OU=Schlumberger, O=slb.com, L=Houston, S=Texas, C=USA\nThumbprint: 3269AC7F6260D4C27B99F7B5778A08E3F55F7B2C\n\nErrors:\n\n The root of the certificate chain is not a trusted root authority..

    Detailed Error:

    Server Error in '/' Application.

    The remote certificate is invalid according to the validation procedure.

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.Security.Authentication.AuthenticationException: The remote certificate is invalid according to the validation procedure.

    Source Error:

    An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

    Stack Trace:

    [AuthenticationException: The remote certificate is invalid according to the validation procedure.]

       System.Net.Security.SslState.StartSendAuthResetSignal(ProtocolToken message, AsyncProtocolRequest asyncRequest, Exception exception) +2348928

       System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer, Int32 count, AsyncProtocolRequest asyncRequest) +86

       System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest) +277

       System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer, Int32 count, AsyncProtocolRequest asyncRequest) +86

       System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest) +277

       System.Net.Security.SslState.ProcessReceivedBlob(Byte[] buffer, Int32 count, AsyncProtocolRequest asyncRequest) +86

       System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer, AsyncProtocolRequest asyncRequest) +277

       System.Net.Security.SslState.ForceAuthentication(Boolean receiveFirst, Byte[] buffer, AsyncProtocolRequest asyncRequest) +7310402

       System.Net.Security.SslState.ProcessAuthentication(LazyAsyncResult lazyResult) +214

       System.Threading.ExecutionContext.runTryCode(Object userData) +376

       System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData) +0

       System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state) +98

       System.Net.TlsStream.ProcessAuthentication(LazyAsyncResult result) +1131

       System.Net.TlsStream.Write(Byte[] buffer, Int32 offset, Int32 size) +88

       System.Net.PooledStream.Write(Byte[] buffer, Int32 offset, Int32 size) +20

       System.Net.ConnectStream.WriteHeaders(Boolean async) +360

    [WebException: The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.]

       System.Net.HttpWebRequest.GetResponse() +1126

       System.ServiceModel.Channels.HttpChannelRequest.WaitForReply(TimeSpan timeout) +81

    [SecurityNegotiationException: Could not establish trust relationship for the SSL/TLS secure channel with authority 'emspeed.test.slb.com:8097'.]

       System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) +10282698

      System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) +539

       FileUploader.ProjectServiceReference.IProjectService.GetClmsDfxHistory(Int32 projectId) +0

       FileUploader.ProjectServiceReference.ProjectServiceClient.GetClmsDfxHistory(Int32 projectId) +103

       FileUploader.FileUpload.UploadTemplate() +5969

       FileUploader.FileUpload.btnUpload_Click(Object sender, EventArgs e) +52

       System.Web.UI.WebControls.Button.OnClick(EventArgs e) +115

       System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +140

       System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +29

       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +2981

    Version Information: Microsoft .NET Framework Version:2.0.50727.8810; ASP.NET Version:2.0.50727.8762

    

    Friday, October 25, 2019 4:13 AM

Answers