Re: Pine for Maildir

2001-04-17 Thread Michael Handler

tc lewis [EMAIL PROTECTED] writes:

 i never cared for mutt either, although i never spent a huge amount of
 time trying to figure it out.  my main issue with it is that i could never
 get it to sort my inbox properly (just normal sorting - by arrival time -
 how the files in the maildir are already sorted).  it could be due to me
 having tried old version of mutt.

set sort=threads
set sort_aux=date-received

If you don't care for the threading behavior, try:

set sort=date-received

-- 
occasional realignment  [EMAIL PROTECTED] (michael handler)
sometimesnecessary  washington, dc



Re: OpenBSD 2.8 You have new mail in /var/mail/root

2001-04-10 Thread Michael Handler

Rick Updegrove [EMAIL PROTECTED] writes:

 bash-2.04# cat /etc/mailer.conf
 #   $OpenBSD: mailer.conf,v 1.3 2000/04/06 18:24:19 millert Exp $
 #
 # Execute the "real" sendmail program, named /usr/libexec/sendmail/sendmail
 #
 sendmail/usr/libexec/sendmail/sendmail
[...]
 Ok so I linked them like this:
 lrwxr-xr-x  1 root  wheel  23 Apr 10 04:04 /usr/libexec/sendmail/sendmail - 
/var/qmail/bin/sendmail

Why would you want to do that? Did you read the manpage for mailer.conf?
It exists exactly so that you don't have to bother touching any symlinks
or such on the filesystem.

root@monster:~# cat /etc/mailer.conf 
# $Id: mailer.conf,v 1.2 2001/04/10 19:36:12 root Exp $
#   $OpenBSD: mailer.conf,v 1.3 2000/04/06 18:24:19 millert Exp $
#
# Execute the "real" sendmail program, named /usr/libexec/sendmail/sendmail
#
sendmail/var/qmail/bin/sendmail
send-mail   /var/qmail/bin/sendmail
mailq   /var/qmail/bin/qmail-qread
newaliases  /bin/echo Functionality unnecessary under qmail
hoststat/bin/echo Functionality unnecessary under qmail
purgestat   /bin/echo Functionality unnecessary under qmail

I suppose I could link newaliases to something that rebuilds fastforward's
CDB, but I don't run fastforward. I suppose hoststat and purgestat could
be set to qmail-tcpto and qmail-tcpok, but that's kind of reaching.

-- 
occasional realignment  [EMAIL PROTECTED] (michael handler)
sometimesnecessary  washington, dc



qmail partial DNS failures

2000-10-19 Thread Michael Handler

If you're a secondary MX for a domain, and your system can resolve the MX
record for the domain, but the resolution of the A record for any lower
preference MX entries fails with a soft DNS error (e.g. timeout), qmail
bounces the message as best-preference-MX-without-further-instructions.

$ dnsqr mx mail.test.sub-rosa.com
15 mail.test.sub-rosa.com:
94 bytes, 1+2+0+0 records, response, noerror
query: 15 mail.test.sub-rosa.com
answer: mail.test.sub-rosa.com 0 MX 0 mx.timeout.test.sub-rosa.com
answer: mail.test.sub-rosa.com 0 MX 100 spool.mail.sub-rosa.com

$ dnsqr a mx.timeout.test.sub-rosa.com
1 mx.timeout.test.sub-rosa.com:
temporary failure

$ dnsq a mx.timeout.test.sub-rosa.com 63.141.2.19
1 mx.timeout.test.sub-rosa.com:
timed out

| Return-Path: 
| Delivered-To: [EMAIL PROTECTED]
| Received: (qmail 32495 invoked for bounce); 19 Oct 2000 14:23:00 -
| Date: 19 Oct 2000 14:23:00 -
| From: [EMAIL PROTECTED]
| To: [EMAIL PROTECTED]
| Subject: failure notice
| 
| Hi. This is the qmail-send program at califia.sub-rosa.com.
| I'm afraid I wasn't able to deliver your message to the following
| addresses.
| This is a permanent error; I've given up. Sorry it didn't work out.
| 
| [EMAIL PROTECTED]:
| Sorry. Although I'm listed as a best-preference MX or A for that host,
| it isn't in my control/locals file, so I don't treat it as local. (#5.4.6)
| 
| --- Below this line is a copy of the message.
| 
| Return-Path: [EMAIL PROTECTED]
| Received: (qmail 32488 invoked by uid 1000); 19 Oct 2000 14:21:37 -
| Date: 19 Oct 2000 14:21:37 -
| Message-ID: [EMAIL PROTECTED]
| From: "Michael Handler" [EMAIL PROTECTED]
| Subject: test
| To: [EMAIL PROTECTED]
| 
| test

Looking through qmail-remote.c, it becomes apparent that in this situation,
dns_mxip() only returns the IP addresses  preferences that it could
resolve completely, with no indication that there were additional lower
preference MX records that were omitted due to soft DNS errors. Thus, when
qmail-remote walks through the list of addresses, it finds itself as the
best-preference MX for the domain, and attempts to handle the mail locally.
Empirical testing bears this diagnosis out:

$ src/qmail-1.03/dnsmxip mail.test.sub-rosa.com
64.0.106.44 100

Scenarios that would run afoul of this are not difficult to imagine: if
domain example.com has MX 0 mx.provider.net and MX 100
spool.mail.sub-rosa.com, and mx.provider.net has a lower TTL than the MX
for example.com, and provider.net's nameservers are unreachable when my
dnscache tries to go resolve mx.provider.net... I think I'm starting to see
why Dan's DNS software encourages using all in-name zones; though even that
is vulnerable if the TTL on the A record is lower than the TTL on the MX
record.

Note that I don't consider this a problem for hard DNS failures, e.g. an MX
record that points at a hostname that authoritatively doesn't exist; that's
what the smtproutes functionality is for. However, I think it's reasonable
for qmail to not bounce messages based on soft DNS failures.

Searching the archives, I note that Chuck Foster noted this problem
wy back in 1997:

http://www.ornl.gov/its/archives/mailing-lists/qmail/1997/07/msg00802.html

It seems to me that the best way to address this is to have dns_mxip return
the full MX list set, with the IP address set to null or 0.0.0.0 for A
records that could not be successfully resolved, and have qmail-remote.c's
for loop skip those MX entries. This would result in temp_noconn() for
these situations, rather than perm_ambigmx().

Note that all of the *.test.sub-rosa.com entries mentioned here exist, and
the tests were done live, with no post-production touchups. Feel free to
poke at my DNS and SMTP servers if you want to do your own tests.

Thoughts?

--michael



Re: procmail and qmail, exitcode, stdout

2000-08-25 Thread Michael Handler

Ronny Haryanto [EMAIL PROTECTED] writes:

 I'm trying to discard emails from somebody and have procmail return a
 hard error code (like 67, 77 or 100) *with* my own brief error message.
 The MTA is qmail. Currently I have "|preline procmail" in my .qmail file.
 I have tried this following recipe with partial success (email is
 discarded and bounced, but my brief error message is not there):
 
 :0
 * ^From:.*abuser@example\.com
 {
 EXITCODE=100
 
 :0
 | echo "Permission denied"
 }

:0
* ^From:.*abuser@example\.com
{
EXITCODE=100

:0 f
| echo "Piss off."

:0 r
|
}

In procmailese, the f flag on the first recipe inside the braces means
"filter", which makes procmail pipe the message through the specified
command, and replace the current message content with the output of the
pipe. For instance:

:0 f
| sed 's/expletive/[expletive deleted]/g'

would be a nice start at sanitizing all email passing through your
.procmailrc. :) In our instance, however, we're piping our message to echo,
which ignores the input it has been offered, and simply outputs our
message, which procmail now takes to be the message body.

The pipe with no argument makes procmail emit the current message to
standard output, with the desired effect. The r flag prevents procmail from
trying to add extraneous \r or \n characters to the output, which are
inappropriate in this context, but appropriate for normal procmail
operation. I added it mostly for aesthetic reasons on the output; try it
both ways and see for yourself.

-- 
[EMAIL PROTECTED] (Michael Handler)  washington, dc



Re: Encryption and t-shirts

2000-02-29 Thread Michael Handler

Vern Hart [EMAIL PROTECTED] writes:

 Here's my latest round of designs:  http://vern.com/tshirts/qmail/
 
 I'll be making at least one more design[1] with a different slogan.
 These will not have the pseudo-sendmail bat for those frightened by
 bats (and pseudo-bats).

As long as we're all wasting people's disk space, this is what I'd like to
see...

Front:

"qmail" stylized text + dolphin logo, as displayed at
http://vern.com/tshirts/qmail/images/dolphin.gif
(though maybe without the URL) on the left breast

Back:

 ("qmail" stylized text)
  (dolphin logo)
   Secure, reliable, efficient.
   Pick three.
  (white space)
  www.qmail.org

I'm not big on wasting lots of space on the shirt with anti-sendmail
verbiage. qmail stands on its own merits, not just in "opposition" to
sendmail -- and if we're going that route I'd be much more inclined to
target postfix. ;) As a more subtle alternative, how about a small copy of
the stylized bat logo, circumscribed by a red crossed circle, off in the
corner? ;)

It's probably time to start a mailing list for qmail t-shirt chatter if
this discussion is going to go on much longer...

-- 
[EMAIL PROTECTED] (Michael Handler)  washington, dc
  polish your pistol / shooting the breeze / flash me your trademark smile
   when you live by the ruler / you die inch by inch / every day is a mile
  -- firewater