M
Mark
I'm having an issue calling a Web Service (This is an 3rd party Web Service
and I have no control/access to it) via HTTPS. We have talked to the
developers and they said their Web Services are working from their end. When
I call their Web Service, though, I keep getting this error:
Web Exception occurred!
Status:SecureChannelFailure
Entire Error Information:System.Net.WebException: The underlying connection
was closed: Could not establish secure channel for SSL/TLS. --->
System.IO.IOException: Unable to write data to the transport connection. --->
System.IO.IOException: Unable to write data to the transport connection. --->
System.Net.Sockets.SocketException: A connection attempt failed because the
connected party did not properly respond after a period of time, or
established connection failed because connected host has failed to respond
at System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32
size, SocketFlags socketFlags)
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset,
Int32 size)
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset,
Int32 size)
at System.Net.TlsStream.InnerWrite(Boolean async, Byte[] buffer, Int32
offset, Int32 size, AsyncCallback asyncCallback, Object asyncState)
--- End of inner exception stack trace ---
at System.Net.TlsStream.EndRead(IAsyncResult asyncResult)
at System.Net.Connection.Write(Byte[] buffer, Int32 offset, Int32 size)
at System.Net.ConnectStream.WriteHeaders(HttpWebRequest httpWebRequest)
--- End of inner exception stack trace ---
at
System.Web.Services.Protocols.WebClientProtocol.GetWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse(WebRequest
request)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String
methodName, Object[] parameters)
The code used to work. About 2-3 weeks ago, I used the same code and it
worked. I had to change the application to add some functionality, but
didn't change the function that called the Web Service. For the past few
days, no matter what I tried, I can't get it to work.
I've read many news articles...
1. I've overloaded GetWebRequest to set the KeepAlive to False.
2. I've created a Certificate Policy to bypass any Certificate issues.
Does anyone have any ideas?
and I have no control/access to it) via HTTPS. We have talked to the
developers and they said their Web Services are working from their end. When
I call their Web Service, though, I keep getting this error:
Web Exception occurred!
Status:SecureChannelFailure
Entire Error Information:System.Net.WebException: The underlying connection
was closed: Could not establish secure channel for SSL/TLS. --->
System.IO.IOException: Unable to write data to the transport connection. --->
System.IO.IOException: Unable to write data to the transport connection. --->
System.Net.Sockets.SocketException: A connection attempt failed because the
connected party did not properly respond after a period of time, or
established connection failed because connected host has failed to respond
at System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32
size, SocketFlags socketFlags)
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset,
Int32 size)
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset,
Int32 size)
at System.Net.TlsStream.InnerWrite(Boolean async, Byte[] buffer, Int32
offset, Int32 size, AsyncCallback asyncCallback, Object asyncState)
--- End of inner exception stack trace ---
at System.Net.TlsStream.EndRead(IAsyncResult asyncResult)
at System.Net.Connection.Write(Byte[] buffer, Int32 offset, Int32 size)
at System.Net.ConnectStream.WriteHeaders(HttpWebRequest httpWebRequest)
--- End of inner exception stack trace ---
at
System.Web.Services.Protocols.WebClientProtocol.GetWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtocol.GetWebResponse(WebRequest
request)
at System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke(String
methodName, Object[] parameters)
The code used to work. About 2-3 weeks ago, I used the same code and it
worked. I had to change the application to add some functionality, but
didn't change the function that called the Web Service. For the past few
days, no matter what I tried, I can't get it to work.
I've read many news articles...
1. I've overloaded GetWebRequest to set the KeepAlive to False.
2. I've created a Certificate Policy to bypass any Certificate issues.
Does anyone have any ideas?