From: Matthias A. <mat...@gm...> - 2006-04-21 23:37:36
|
Ratan Nalumasu <nal...@ya...> writes: > Hi all: > > I am still struggling a bit with the configuration. As > suggested, I am going to describe what I am trying to achieve > and then explain what I have done so far. > > - I want to download mail from the mailserver to my laptop, > leaving an empty mailbox on the server. That alone is easy. Don't use --keep and perhaps use --fetchall. > - The mailserver currently has IMAP and POP3 ports open, > though POP3 may be closed in the future. There is no server > on the POP3S port as we speak though. Does the POP3 port offer STLS? If it does, no need for POP3S. > - Ideally, I don't want to enter the password to fetchmail, > but have it use my ssh-agent if available and fail if not. Your configuration does that. > - I sometimes read the mail directly on the mail server > using squirrelmail and elm. That will only work until fetchmail has downloaded the messages. After that, your requirement "empty mailbox after fetch" prevents that. > In these cases, the messages are being marked as Read on the server > ("Status: RO"). However, when I get them using fetchmail on IMAP > protocol, the Status line disappears in the fetched e-mail. This looks a bit like a server issue. Fetchmail would mark downloaded messages read (rather than marking read messages unread), but as per your description the effect is quite the opposite. What I find most peculiar though is that (judging from the -v -v log) fetchmail marks the messages as seen and deleted, sends an EXPUNGE command that logs the two messages as expunged, and apparently the messages are still there (else you wouldn't have messages marked unread, but the messages should be gone). Any idea? > - When I fetch the same mail using fetchmail on POP3 protocol, > the "Status" fields are retained but it leads to a different > problem: insufficient integration with ssh/ssh-agent. Yes, that requires some experimenting on how exactly to start the server, and not all support it, since it's not standardized. > After some research, I tried the following to force it to use > ssh; but the results were still not good: this configuration > still asks for password; if I enter a bad password, the > authentication fails: i.e., apparently, unlike imap server, the > pop3 server has no preauthorized state. Well, it's possible to trick some servers into a similar state, but sometimes this requires wrapper scripts to get synchronization (who talks first) right. > ==== pop3, attempt#2 === > poll bitter with pop3 via localhost port 8005 > uidl > preconnect "ssh -n -2 -a -C -f ratan@bitter -L > 8005:bitter:110 sleep 5" > > ====== > > Any suggestions on how I can get the mail while retaining the > "Seen" flags exclusively using the ssh-agent for connection > would be great. > > BTW, I tried fetchmail version 6.3.4 and 6.2.5.2 both with the > same results. The basic code and how it works is mostly unchanged, but 6.3.4 has a slew of bugs less than 6.2.5.X, so you might want to stick with 6.3.4 nonetheless. -- Matthias Andree |