>From a machine somewhere near Chris Thompson:
> When I get through to the (putatively) human being in charge of the list,
> I sometimes get replies like "I've removed such-and-such@??? from
> the mailing list, but it would save you and us trouble if your mail system
> generated error messages in standard format, because then the unsubscribing
> would happen automatically". These references to "standard format" do not
> mention any RFC... :-)
I've seen the opposite end of this problem. I run a sort of a BBS which
sends out a regular newsletter to all it's users, and quite often,
particularly at this time of year, I recieve back bounces from accounts
that have been removed. I've got a script, which I'm forever adjusting
and tuning, which recieves the bounces and bans the account on my BBS,
giving a suitible "reason" message. If the user tries to log in, they
are forbidden, and told why they're banned, and who to contact, and if
they don't sort their email address out within a couple of months, I
blow away their account completely.
I've made part of my job easy. Each newsletter is sent out with a title
line saying "<BBS> Newsletter Issue <XX> sent to <ACCOUNT>", and by
recognising this line in the mail-bounces, my script immediately knows
WHICH ACCOUNT needs to be banned, regardless of any daft re-writings and
forwardings and things that might have ruinned their email address.
My problem is finding the excuse. Essentially what I've found is that
there DEFINITELY IS NO STANDARD FORMAT FOR BOUNCE MESSAGES. Probably the
most standard would be whatever sendmail sends back, but I've seen SO
MANY different types that it's really annoying.
It's not quite the same problem, but in case it helps, here are the
rules my script has ended up with which USUALLY find the important few
lines of the bounce message. These occur in approximatelyt the order I
encountered them, so probably roughly most-popular-first. I'm usually
interested in the "BLAHBLAH" to put in my "you are banned because"
messages.
--------8<----------8<-------- Cut here --------8<----------8<--------
/^Your message was not delivered to/ ADDR
/for the following reason:/
BLAHBLAH
/^\*\*\*\*\* The following information/
--------8<----------8<-------- Cut here --------8<----------8<--------
/^<<< MAIL FROM:/ BLAH
BLAHBLAH
/^<<< DATA/
--------8<----------8<-------- Cut here --------8<----------8<--------
/^responses from the mail transport system/
BLAHBLAH
/^Should you need assistance, please mail/
--------8<----------8<-------- Cut here --------8<----------8<--------
^ *----- Transcript of session follows -----$/
BLAHBLAH
/----- Unsent message follows -----/
or /----- Original message follows -----/
--------8<----------8<-------- Cut here --------8<----------8<--------
/^Bad address/ BLAHBLAH
/^Error --/ BLAHBLAH
--------8<----------8<-------- Cut here --------8<----------8<--------
then the mime-like
/^Content-Description: Session Transcript/
BLAHBLAH
/^Content-Description:/
--------8<----------8<-------- Cut here --------8<----------8<--------
/SMTP error from remote/
BLAHBLAH
/^------/
--------8<----------8<-------- Cut here --------8<----------8<--------
Then exim's
/This message was created automatically by mail delivery/
WAFFLE
/following address.* failed/
BLAHBLAH
/^------/
--------8<----------8<-------- Cut here --------8<----------8<--------
I then have a default rule so that if none of the above have found an
"excuse", I say "your email has bounced 'for some reason'".
I currently seem to have 40 banned accounts and 4 of them DO NOT have
nice excuses, so I guess the above 8 rules cover approximately 90% of
the error-responses I get, but who knows how many rules I'd need to
match all bounces?
I suspect that if you want majordomo, listserv, and all the other
obvious list-programs to "work properly", your best hope is to emulate
sendmail's bounces, at least in part. try mailing
"this.user.does.not.exist@???"
and see what the bounce looks like. Stick something very similar-looking
above your human-readable message, and good luck to you!
Nick Waterman, Network Manager, Cimio Ltd. nick@???
http://www.cimio.co.uk/~nick/ Team AMIGA! #include <stddisclaimer.h>
Your computer is dead, and it was so alive.
You shouldn't have installed... Win'95.