fetchmail-friends
[Top] [All Lists]

[fetchmail] Bug in fetchmail 6.2.1 - please take a look!

2003-04-27 15:05:33
OK, now I'm pretty convinced there is a bug in fetchmail. Hopefull some
maintainers do read this mailing list, and so can take a look at this
and/or discuss with me. I'm cc'ing the debian list because that's what I
use, and cyrus because it affects my forwarding of emails into
cyrus-imap as well.

I'm seeing the same behavoir in both the version with fetchmail in
debian stable (5.9.11) and debian testing (6.2.1), and I am fairly
convinced that this is a bug. At the least, the behavoir doesn't seem
ideal.

The long and short of it is the following. Here is a line from my
.fetchmailrc, altered a bit (passwords removed, for instance):

poll mail.lippman.org protocol pop3 user "testuser" pass "testpass" is 
        "test" smtphost "/var/imap/socket/lmtp"

This line should retrieve mail from my pop3 server and forward it via
lmtp to a socket which cyrus-imap's lmtp daemon is listing on.

If I send multiple messages to this email account, then then invoke
fetchmail to retrieve them, the first message is lost. This is true no
matter how messages are waiting for retrieval when fetchmail runs; the
first is always lost (if there is only one message waiting, it is of
course lost). The reason is that fetchmail tries to forward the first
message to "test@/var/imap/socket" which fails, because the lmtp daemon
(correctly) notes that this is incorrect syntax for an email address.
Fetchamil seems to pick up on this error (although the log does not
indicate that it is doing so), because all subsequent messages are then
fowarded to "test(_at_)localhost" which the lmtpd accepts. This behavoir, as
mentioned, occurs with 5.9.11 AND 6.2.1 versions. I would assume this
would affect anyone using fetchmail as a forwarding agent to a server
listing on a unix socket rather than an inet socket, but I haven't seen
prior postings (other than mine, which have never generated any
responses).

Any thoughts/comments appreciated.

For reference, here's the output of fetchmail -vv which shows the
problem (see the line where I added *******!).

nl

==================
Output from fetchmail -vv

fetchmail: 6.2.1 querying mail.lippman.org (protocol POP3) at Sun Apr 27 
17:55:30 2003: poll started
fetchmail: POP3< +OK Hello there.
fetchmail: POP3> CAPA
fetchmail: POP3< +OK Here's what I can do:
fetchmail: POP3< TOP
fetchmail: POP3< USER
fetchmail: POP3< LOGIN-DELAY 10
fetchmail: POP3< PIPELINING
fetchmail: POP3< UIDL
fetchmail: POP3< IMPLEMENTATION Courier Mail Server
fetchmail: POP3< .
fetchmail: POP3> USER testuser
fetchmail: POP3< +OK Password required.
fetchmail: POP3> PASS *
fetchmail: POP3< +OK logged in.
fetchmail: selecting or re-polling default folder
fetchmail: POP3> STAT
fetchmail: POP3< +OK 4 3061
fetchmail: POP3> LAST
fetchmail: POP3< -ERR Invalid command.
fetchmail: POP3> UIDL
fetchmail: POP3< +OK
fetchmail: POP3< 1 1051479403.23899_87.mail-hub-1.omnis.com
fetchmail: POP3< 2 1051479403.23899_93.mail-hub-1.omnis.com
fetchmail: POP3< 3 1051479751.24771_50.mail-hub-1.omnis.com
fetchmail: POP3< 4 1051479797.24889_22.mail-hub-1.omnis.com
fetchmail: POP3< .
4 messages (1 seen) for testuser at mail.lippman.org (3061 octets).
fetchmail: POP3> LIST
fetchmail: POP3< +OK POP3 clients that break here, they violate STD53.
fetchmail: POP3< 1 772
fetchmail: POP3< 2 763
fetchmail: POP3< 3 763
fetchmail: POP3< 4 763
fetchmail: POP3< .
skipping message testuser(_at_)mail(_dot_)lippman(_dot_)org:1 (772 octets) not 
flushed
fetchmail: POP3> TOP 2 99999999
fetchmail: POP3< +OK headers follow.
reading message testuser(_at_)mail(_dot_)lippman(_dot_)org:2 of 4 (763 octets)
About to rewrite Return-Path: <nl(_at_)lippman(_dot_)org>
Rewritten version is Return-Path: <nl(_at_)lippman(_dot_)org>
About to rewrite From: Neal Lippman <nl(_at_)lippman(_dot_)org>
Rewritten version is From: Neal Lippman <nl(_at_)lippman(_dot_)org>
About to rewrite To: test(_at_)lippman(_dot_)org
Rewritten version is To: test(_at_)lippman(_dot_)org
fetchmail: LMTP< 220 rivendell LMTP Cyrus v2.1.12 ready
fetchmail: LMTP> LHLO localhost
fetchmail: SMTP< 250-rivendell
fetchmail: SMTP< 250-8BITMIME
fetchmail: SMTP< 250-ENHANCEDSTATUSCODES
fetchmail: SMTP< 250-PIPELINING
fetchmail: SMTP< 250-SIZE
fetchmail: SMTP< 250-AUTH EXTERNAL
fetchmail: SMTP< 250 IGNOREQUOTA
fetchmail: forwarding to /var/imap/socket/lmtp
fetchmail: LMTP> MAIL FROM:<nl(_at_)lippman(_dot_)org> BODY=7BIT SIZE=763
fetchmail: LMTP< 250 2.1.0 ok
fetchmail: LMTP> RCPT TO:<test@/var/imap/socket>        **** HERE'S the problem 
line
fetchmail: LMTP< 501 5.5.4 Syntax error in parameters
fetchmail: SMTP> RCPT TO:<nl@/var/imap/socket>
fetchmail: SMTP< 501 5.5.4 Syntax error in parameters
fetchmail: SMTP> RSET
fetchmail: SMTP< 250 2.0.0 ok
fetchmail: message testuser(_at_)mail(_dot_)lippman(_dot_)org:2 was not the 
expected length (785 actual != 763 expected)
 flushed
fetchmail: POP3> DELE 2
fetchmail: POP3< +OK Deleted.
fetchmail: POP3> TOP 3 99999999
fetchmail: POP3< +OK headers follow.
reading message testuser(_at_)mail(_dot_)lippman(_dot_)org:3 of 4 (763 octets)
About to rewrite Return-Path: <nl(_at_)lippman(_dot_)org>
Rewritten version is Return-Path: <nl(_at_)lippman(_dot_)org>
About to rewrite From: Neal Lippman <nl(_at_)lippman(_dot_)org>
Rewritten version is From: Neal Lippman <nl(_at_)lippman(_dot_)org>
About to rewrite To: test(_at_)lippman(_dot_)org
Rewritten version is To: test(_at_)lippman(_dot_)org
fetchmail: forwarding to /var/imap/socket/lmtp
fetchmail: SMTP> MAIL FROM:<nl(_at_)lippman(_dot_)org> BODY=7BIT SIZE=763
fetchmail: SMTP< 250 2.1.0 ok
fetchmail: SMTP> RCPT TO:<test(_at_)localhost>          **** BUT this one's 
fixed!
fetchmail: SMTP< 250 2.1.5 ok
fetchmail: SMTP> DATA
fetchmail: SMTP< 354 go ahead
#fetchmail: message test(_at_)mail(_dot_)lippman(_dot_)org:3 was not the 
expected length (785 actual != 763 expected)
fetchmail: SMTP>. (EOM)
fetchmail: SMTP< 250 2.1.5 Ok
fetchmail: terminated with signal 2
fetchmail: Writing fetchids file.


<Prev in Thread] Current Thread [Next in Thread>