Re: The underlying connection was closed



John,

1) The solutions I was finding on the web were all based on the 1.1 and 1.0
framework. They involved tweaking the resource.cs file by overriding the
WebRequest method and setting the KeepAlive = false. Basicly, force the
creation of a new connection for every request. I guess that MS had a
support item on it at
'http://support.microsoft.com/default.aspx?scid=kb%3ben-us%3b819450' but
they have since removed the topic.
I can't follow the recommend because in VS 2005, there is no resource.cs
file any more. this file is generated on the fly by the .net framework
after deployment.

2) the web service is configured for ssl using a purchased certificate.
When my client hits my ws using https, my call to the 3rd party ws fails
with the error stated. If I allow my client to hit my ws without ssl, my
call to the 3rd party ws works just fine. In both cases I am hitting the
3rd party ws using ssl.

Kirk

"John Saunders [MVP]" <john.saunders at trizetto.com> wrote in message
news:uJOhQeRgHHA.4260@xxxxxxxxxxxxxxxxxxxxxxx
"kirk" <nokirkspam@xxxxxxxxxxxxxxxxx> wrote in message
news:uip$7TQgHHA.4916@xxxxxxxxxxxxxxxxxxxxxxx
Environment:
c#, Framwork 2.0, Win2003 server, IIS 6.0, Copy deployment (uncompiled
source code deployed to server)

I have written a web service that calls another web service. The ws I am
calling is third party, but written in .net (unknown framework version).
I am calling the 3rd party ws over https.
When my ws is called without ssl everything works great. However, when
my client is calling my ws using https, I get the following error:

The underlying connection was closed: An unexpected error occurred on a
receive.
System.Net.WebResponse GetWebResponse(System.Net.WebRequest)
...

I won't post the entire stack trace for size reasons.
The error will only pop up after a number of days of everything working
just fine. No changes on the server or the source code.

I have seen a number of 'solutions' to this problem, but they all apply
to 1.0 and 1.1 frameworks.

What did those solutions say was the cause of the problem?

Does anyone know why this is happening and what I can do about it in 2.0?

I don't know for sure what's happening, but does your web server have SSL
configured?
--

John Saunders [MVP]




.



Relevant Pages

  • Re: The underlying connection was closed
    ... this file is generated on the fly by the .net framework ... the web service is configured for ssl using a purchased certificate. ... When my client hits my ws using https, my call to the 3rd party ws fails ...
    (microsoft.public.dotnet.framework.aspnet.webservices)
  • Re: Using CAPI to encrypt in AES CBC mode without padding
    ... Faris's framework. ... Get your indirectly exploding clarity behind my ... party. ... it concerns a rush too successful away from her ...
    (sci.crypt)
  • Re: Failed to access IIS Meatbase
    ... framework 2.0, I get the "Failed to access IIS Metabase" error message. ... When I try to run the VssService.asmx web service for sourcesafe, ... Can I run the web service for source safe from within a browser to see ...
    (microsoft.public.vstudio.sourcesafe)
  • Cant see 401 qualification on web exception on PDA
    ... credentials sent in a SOAP header. ... If I call that web service from a .NET Full Framework ... If I call that web service from a .NET COMPACT Framework ... client with an incorrect ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: Mix Dot Net 2 and Dot Net 1
    ... provides GUI framework as well as web service and database for the in- ... Dot Net 2.0 with VS 2005. ... Services and Oracle database. ... almost all new features of the 2.0 framework and winforms. ...
    (microsoft.public.dotnet.framework.windowsforms)