I have a private email sending application (Windows), which sends email notifications over SMTP protocol. This might look like a code question for StackOverflow, but it is not. The application works fine and its email sending function works great. The problem is that in some systems, in particular on my Windows 7 Ultimate desktop system, outgoing connections are blocked by something I have hard time identifying.
The problem I see is that at some point very soon from establishing the connection, the socket connection is closed with code 10053
, which is 0x2745
, which is WSAECONNABORTED
, which is "An established connection was aborted by the software in your host machine.". In my host machine, and this is about right - remote server is not the source of disconnection. Sometimes the application still have time to send receive 1-2 messages before the channel is faithfully destroyed by the power from above.
My first guess was that it is simple, it has to be the firewall or antivirus. The only software of this kind that have is built in firewall, and Windows Defender. Turning firewall off is not helpful, Defender is not set to do any real time activity, just is run on demand. The machine is not a part of domain or something - pure standalone.
To add to this, I tried sending over SSL and TLS secure connections and it is not helpful. In the same time I have no problems sending to Google Mail servers. I don't know what makes such a difference, it might be SSL certificate from Google servers in good standing, but it is only particular case.
The questions are: given that the activity is to open socket to remote SMTP server and do the mail thing, what might be the cause in Windows to forcefully close this connection? Are there any tools to troubleshoot this, to find the cause and disable it?
2013-08-08 Update:
WireShark shows the following TCP session:
1
Thunderbird sends the emails my app cannot,2
The error code is indicating internal cause (within my computer),3
I can see a couple of initial SMTP messages such as EHLO handshaking before connection is closed, so the connection is established first and only then later is closed for some reason.