fetchmail-friends
[Top] [All Lists]

RE: [fetchmail]Socket Error on small e-mails

2004-05-28 05:39:32
Here's the output of openssl when I try to retrive that message that messes up 
fetchmail.  It sits there for a min, and then there's that
"read:errno=0" line.  I'm still not sure what's going on.

root(_at_)jcgerm:~# openssl s_client -connect 198.82.161.8:995
CONNECTED(00000003)
depth=0 /C=US/ST=Virginia/L=Blacksburg/O=Virginia Polytechnic Institute and 
State University/OU=Systems Engineering and Administration/CN=pop.vt.edu
verify error:num=20:unable to get local issuer certificate
verify return:1
depth=0 /C=US/ST=Virginia/L=Blacksburg/O=Virginia Polytechnic Institute and 
State University/OU=Systems Engineering and Administration/CN=pop.vt.edu
verify error:num=27:certificate not trusted
verify return:1
depth=0 /C=US/ST=Virginia/L=Blacksburg/O=Virginia Polytechnic Institute and 
State University/OU=Systems Engineering and Administration/CN=pop.vt.edu
verify error:num=21:unable to verify the first certificate
verify return:1
---
Certificate chain
 0 s:/C=US/ST=Virginia/L=Blacksburg/O=Virginia Polytechnic Institute and State 
University/OU=Systems Engineering and Administration/CN=pop.vt.edu
   i:/C=ZA/ST=Western Cape/L=Cape Town/O=Thawte Consulting cc/OU=Certification 
Services Division/CN=Thawte Server 
CA/emailAddress=server-certs(_at_)thawte(_dot_)com
---
Server certificate
-----BEGIN CERTIFICATE-----
MIIDYTCCAsqgAwIBAgIDPd7OMA0GCSqGSIb3DQEBBAUAMIHEMQswCQYDVQQGEwJa
QTEVMBMGA1UECBMMV2VzdGVybiBDYXBlMRIwEAYDVQQHEwlDYXBlIFRvd24xHTAb
BgNVBAoTFFRoYXd0ZSBDb25zdWx0aW5nIGNjMSgwJgYDVQQLEx9DZXJ0aWZpY2F0
aW9uIFNlcnZpY2VzIERpdmlzaW9uMRkwFwYDVQQDExBUaGF3dGUgU2VydmVyIENB
MSYwJAYJKoZIhvcNAQkBFhdzZXJ2ZXItY2VydHNAdGhhd3RlLmNvbTAeFw0wNDAz
MDMxNDQwMzdaFw0wNTAzMDMxNDQwMzdaMIG5MQswCQYDVQQGEwJVUzERMA8GA1UE
CBMIVmlyZ2luaWExEzARBgNVBAcTCkJsYWNrc2J1cmcxPDA6BgNVBAoTM1Zpcmdp
bmlhIFBvbHl0ZWNobmljIEluc3RpdHV0ZSBhbmQgU3RhdGUgVW5pdmVyc2l0eTEv
MC0GA1UECxMmU3lzdGVtcyBFbmdpbmVlcmluZyBhbmQgQWRtaW5pc3RyYXRpb24x
EzARBgNVBAMTCnBvcC52dC5lZHUwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGB
ALyLJKcEIZ3Msa4Dm8KklpmO0F3vkuChF3ll/tPlXbitVq2H2bkIn3cJqyowO7yX
YTwUjF6EhrtYIjZPuCtZKs9BryvCSkpmcjdKOmie355u2vwl7zuVnLjgsrSii6k/
qf9xScLJDM7eI1S4SpQF6gjh1H95rniOWRNEWvBw3MKJAgMBAAGjajBoMB0GA1Ud
JQQWMBQGCCsGAQUFBwMBBggrBgEFBQcDAjA5BgNVHR8EMjAwMC6gLKAqhihodHRw
Oi8vY3JsLnRoYXd0ZS5jb20vVGhhd3RlU2VydmVyQ0EuY3JsMAwGA1UdEwEB/wQC
MAAwDQYJKoZIhvcNAQEEBQADgYEAgrr6i1h0kv1X/lCAkHYQf/QiKffkl00amJGD
xgZgDsn9M4474JbaXKxDVGVCJs0Fcfdbr/af1BV5m8i84Qes4QA1KvqRuVo56PS+
TXWZvNBOgUth9VBz7qIguG1yKs6SAzxrASEA8QOzK8rahjJPv6mLZAuMLotPGIMI
sX7WXIQ=
-----END CERTIFICATE-----
subject=/C=US/ST=Virginia/L=Blacksburg/O=Virginia Polytechnic Institute and 
State University/OU=Systems Engineering and Administration/CN=pop.vt.edu
issuer=/C=ZA/ST=Western Cape/L=Cape Town/O=Thawte Consulting 
cc/OU=Certification Services Division/CN=Thawte Server 
CA/emailAddress=server-certs(_at_)thawte(_dot_)com
---
No client certificate CA names sent
---
SSL handshake has read 1023 bytes and written 332 bytes
---
New, TLSv1/SSLv3, Cipher is DES-CBC3-SHA
Server public key is 1024 bit
SSL-Session:
    Protocol  : TLSv1
    Cipher    : DES-CBC3-SHA
    Session-ID: 
B6AB58F12812AA183DF84B4BFD6113DB05561180CA92B6838220A1950C444A15
    Session-ID-ctx:
    Master-Key: 
8C44EB3966D37DE4517C8C6DBC7F162B55CA03C6BAF78ECBC4776013299629A52B395F802385AD
406196FCCD11A888AD
    Key-Arg   : None
    Start Time: 1085747670
    Timeout   : 300 (sec)
    Verify return code: 21 (unable to verify the first certificate)
---
+OK lyta.cc.vt.edu POP3 service (iPlanet Messaging Server 5.2 Patch 1 (built 
Aug 19 2002))
user jfried
+OK Name is a valid mailbox
pass ***************
+OK Maildrop ready
stat
+OK 820 10304422
retr 1
+OK 1430 octets
Return-path: <kajopjvsow(_at_)medbstea(_dot_)com>
Received: from dagger.cc.vt.edu (evil-dagger.cc.vt.edu [10.1.1.11])
 by lyta.cc.vt.edu (iPlanet Messaging Server 5.2 Patch 1 (built Aug 19 2002))
 with ESMTP id <0HX000C9KQ0USW(_at_)lyta(_dot_)cc(_dot_)vt(_dot_)edu>; Sat,
 01 May 2004 00:34:08 -0400 (EDT)
Received: from cpe-65-26-82-225.kc.rr.com
 (CPE-65-26-82-225.kc.rr.com [65.26.82.225])    by dagger.cc.vt.edu (MOS 
3.4.6-GR)
        with SMTP id ASM39052; Sat, 01 May 2004 00:34:04 -0400 (EDT)
Received: from 97.15.132.155 by 65.26.82.225; Fri, 30 Apr 2004 23:40:02 -0600
Date: Sat, 01 May 2004 06:38:02 +0100
From: Vilma Pacheco <kajopjvsow(_at_)medbstea(_dot_)com>
Subject: Valium Ambien Xanax and More, Fri, 30 Apr 2004 22:42:02 -0700
To: jablevin(_at_)vt(_dot_)edu
Cc: jfried(_at_)vt(_dot_)edu, smansi(_at_)vt(_dot_)edu, 
kbelcher(_at_)vt(_dot_)edu
Reply-to: Vilma Pacheco <kajopjvsow(_at_)medbstea(_dot_)com>
Message-id: <ONEAMCAZWZBPISTOAVVD(_at_)medbstea(_dot_)com>
MIME-version: 1.0
Content-type: multipart/alternative; boundary=--506268834230434501
X-Junkmail-Status: score=11/50, host=dagger.cc.vt.edu

----506268834230434501
Content-Type: text/plain;
Content-Transfer-Encoding: quoted-printable

refill #  =20v8cxj64242

We deliver the best=20 anti depresent, pain reliver , alergy meds and mroe=
=20
thats discreetly shipped to your door

http://www.go.com.qmedshopw.com/gp/default.asp?id=3Dcal

WDF International Imports Inc, North Front St. #1073, Belize City, Belize.

----506268834230434501--

.
read:errno=0

===== Original Message From Brian Candler 
<B(_dot_)Candler(_at_)pobox(_dot_)com> =====
On Fri, May 28, 2004 at 06:58:50AM -0400, Jeremy Fried wrote:
Does it work if you pull down *without* SSL?

No -> then we can use tcpdump to try and see what's happening.
Yes -> hmm, difficult to debug. Need to stick extra debugging printf's
in
the code.

No, I can't get my mail any other way.  I'm forced to use SSL.  How can
we use tcpdump to see what's going on?

You look at the packet contents to work out which end is violating the
protocol or which end has decided to drop the connection prematurely.

This is no use with SSL though, where the whole point of SSL is that the
traffic is encrypted, so you *can't* see what's going on.

However, in the first instance I'd try driving it manually:

  $ script pop3.log
  $ openssl s_client -connect x.x.x.x:995
  user USERNAME
  pass PASSWORD
  stat
  retr 1
  ... etc
  quit
  $ exit

where x.x.x.x is the name or IP of the POP3 server. What do you see when you
try to 'retr' one of these messages which causes the breakage? If the server
is dropping the connection, or if the message does not end \r\n.\r\n, then
complain to the server vendor.

After that, you'll probably have to start putting printf's in the fetchmail
code.

Brian.