473,406 Members | 2,707 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

The underlying connection was closed: An unexpected error occurred on a send

Hi!
I have a problem - after deploying application in client
environment, on some client machines occured error.
Environment:
App server: ASP.NET WebService/Win 2003/ secured SSL (.NET 2.0)
Client app: SmartClient - WinForms (.NET 2.0)

I trust all server cetrificates - at the start of client application
I call:

System.Net.ServicePointManager.ServerCertificateVa lidationCallback +=
delegate(
object sender,
System.Security.Cryptography.X509Certificates.X509 Certificate certificate,
System.Security.Cryptography.X509Certificates.X509 Chain chain,
System.Net.Security.SslPolicyErrors sslPolicyErrors)
{
return true;
};

Any ideas?
Regards

Mrozik
Error stack:

System.Net.WebException: The underlying connection was closed: An
unexpected error occurred on a send. ---System.IO.IOException: The
handshake failed due to an unexpected packet format.
at System.Net.Security.SslState.StartReadFrame(Byte[] buffer, Int32
readBytes, AsyncProtocolRequest asyncRequest)
at System.Net.Security.SslState.StartReceiveBlob(Byte[] buffer,
AsyncProtocolRequest asyncRequest)
at
System.Net.Security.SslState.CheckCompletionBefore NextReceive(ProtocolToken
message, AsyncProtocolRequest asyncRequest)
at System.Net.Security.SslState.StartSendBlob(Byte[] incoming, Int32
count, AsyncProtocolRequest asyncRequest)
at System.Net.Security.SslState.ForceAuthentication(B oolean
receiveFirst, Byte[] buffer, AsyncProtocolRequest asyncRequest)
at System.Net.Security.SslState.ProcessAuthentication (LazyAsyncResult
lazyResult)
at System.Net.TlsStream.CallProcessAuthentication(Obj ect state)
at System.Threading.ExecutionContext.runTryCode(Objec t userData)
at
System.Runtime.CompilerServices.RuntimeHelpers.Exe cuteCodeWithGuaranteedCleanup(TryCode
code, CleanupCode backoutCode, Object userData)
at System.Threading.ExecutionContext.RunInternal(Exec utionContext
executionContext, ContextCallback callback, Object state)
at System.Threading.ExecutionContext.Run(ExecutionCon text
executionContext, ContextCallback callback, Object state)
at System.Net.TlsStream.ProcessAuthentication(LazyAsy ncResult result)
at System.Net.TlsStream.Write(Byte[] buffer, Int32 offset, Int32 size)
at System.Net.PooledStream.Write(Byte[] buffer, Int32 offset, Int32
size)
at System.Net.ConnectStream.WriteHeaders(Boolean async)
--- End of inner exception stack trace ---
at
System.Web.Services.Protocols.WebClientProtocol.Ge tWebResponse(WebRequest
request)
at
System.Web.Services.Protocols.HttpWebClientProtoco l.GetWebResponse(WebRequest
request)
at System.Web.Services.Protocols.SoapHttpClientProtoc ol.Invoke(String
methodName, Object[] parameters)
Jul 18 '07 #1
1 8808
On Wed, 18 Jul 2007 09:30:37 +0200, Mrozik <mr******@interia.plwrote:
Hi!
I have a problem - after deploying application in client
environment, on some client machines occured error.
Environment:
App server: ASP.NET WebService/Win 2003/ secured SSL (.NET 2.0)
Client app: SmartClient - WinForms (.NET 2.0)

I trust all server cetrificates - at the start of client application
I call:

System.Net.ServicePointManager.ServerCertificateVa lidationCallback
+= delegate(
object sender,
System.Security.Cryptography.X509Certificates.X509 Certificate
certificate,
System.Security.Cryptography.X509Certificates.X509 Chain chain,
System.Net.Security.SslPolicyErrors sslPolicyErrors)
{
return true;
};

Any ideas?
Regards

Mrozik
Error stack:

System.Net.WebException: The underlying connection was closed: An
unexpected error occurred on a send. ---System.IO.IOException: The
handshake failed due to an unexpected packet format.
[...]
I think it's configuration issue - error occured when client applications
connect to WebService using IP in address. When I change configuration and
try to
connect using machine name everything works OK.
But why error appears when using IP in WebService address - and only on
some machines?
Mrozik
Jul 18 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

26
by: Rajeev Tipnis | last post by:
http://support.microsoft.com/default.aspx?scid=kb;en- us;819450 Questions: 1) Is this patch (fix) applicable to the .NET 1.1 Framework as well? That is, if we have Framework 1.1 (On...
1
by: Fredrik L | last post by:
Hi, We have an application outside the firewall who talks to a webservice inside the firewall. 9 times of 10 this works, but sometimes we got the error "The underlying connection was closed: An...
5
by: Vijayakrishna Pondala | last post by:
Hi, We are using the following error randomly, when accessing a webservice method/servlet hosted on JBoss application server: The underlying connection was closed: An unexpected error occurred...
4
by: Matthew.DelVecchio | last post by:
hello, i am developing an ASP.NET web app that consumes a 3rd party vendor webservice. it is my first one so while ive done my homework, im not an expert on the matter. our partner's...
3
by: Rahul Anand | last post by:
As per our requirements we have a web service which internally connects (Simple HTTP Post Request) to a remote server to initiate some work. We are calling the web service method asynchronously...
0
by: Mahesh Devjibhai Dhola | last post by:
Hi, I am getting the following exception when using webservice.. "The underlying connection was closed: An unexpected error occurred on a receive" I am not getting any innerexception so no clue...
2
by: Andrew Hunot | last post by:
I have VB code in VS2003 which creates a HttpWebRequest and performs a POST operation to a remote URL (an https site), which runs fine and receives a valid response. However exactly the same...
5
by: =?Utf-8?B?V2VsdVI=?= | last post by:
I have a web client application built on .Net Frameworks 2.0 that connects to a web service on IIS 6.0 via SSL and using X509 Client Certificates. At some locations (it works at others), I get the...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.