🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: comp.mail.sendmail
5 messages
5 total messages Started by Teruhiko Kurosaka Wed, 30 Nov 1988 23:09
Filtering junk mail
#2992
Author: Teruhiko Kurosaka
Date: Wed, 30 Nov 1988 23:09
16 lines
1133 bytes
Does anyone out there knows any way to insert a filter program
in the sendmail daemon so that a piece of e-mail that meets
a certain criteria (such as addressed to an alias but not addressed
to the user directly) goes to a designated folder automatically, or
just be thrown away?
I am receiving a lot of junk e-mails through an alias that I am
forced to be a member of.  I am interested in have sendmail automatically
sort out these pices of junk e-mail.
I have a feeling that the same trick "vacation" program uses can be
used for this purpose and am wondering if anybody has already experienced
this.
Please address your reply directly to kuro@sun.com because I don't
check this news group so frequently.
Thank you in advance.

T. Kurosaka (kuro@sun.com)
Re: Filtering junk mail
#2977
Author: Chip Salzenberg
Date: Fri, 02 Dec 1988 20:47
43 lines
2062 bytes
[ Followups to comp.mail.misc ]

According to kuro%shochu@Sun.COM (Teruhiko Kurosaka):
>Does anyone out there knows any way to insert a filter program
>in the sendmail daemon so that a piece of e-mail that meets
>a certain criteria (such as addressed to an alias but not addressed
>to the user directly) goes to a designated folder automatically, or
>just be thrown away?

This is a common desire, thus the followup here instead of E-Mail.

My "deliver" program, recently posted to comp.sources.unix and currently at
patch level 6, should satisfy your needs quite nicely.

You could use your .forward file to hand all your mail to "deliver":

	"|/usr/bin/deliver kuro"

Then your could write a delivery file that puts each message in a mailbox
that depends on the contents of the "To:" line.  An example:

	# /usr/kuro/.deliver
	# Separate mail into mailboxes, depending on the "To:" address.
	# Note that multi-line "To:" addresses aren't handled yet.

	user="$1"
	to="`sed -n 's/^To: //p' $HEADER`"

	case "$to" in
	*junk-alias*)   ;; # Throw it away!
	*foo-alias*)    echo "$user":foo-mailbox ;;
	*bar-alias*)    echo "$user":bar-mailbox ;;
	*)              echo "$user":normal-mailbox ;;
	esac

This is just an example.  You can get as fancy as you like.

If you didn't pick up deliver, check with your site admin; and if he can't
help you, write me back and I'll see what I can do.
-- 
Chip Salzenberg             <chip@ateng.com> or <uunet!ateng!chip>
A T Engineering             Me?  Speak for my company?  Surely you jest!
	   Beware of programmers carrying screwdrivers.
Re: Filtering junk mail
#2978
Author: Mark Sirota
Date: Sat, 03 Dec 1988 20:22
15 lines
1150 bytes
In article <79561@sun.uucp> kuro@sun.UUCP (Teruhiko Kurosaka) writes:
> Does anyone out there knows any way to insert a filter program
> in the sendmail daemon so that a piece of e-mail that meets
> a certain criteria (such as addressed to an alias but not addressed
> to the user directly) goes to a designated folder automatically, or
> just be thrown away?

This does not belong in sendmail, since it is something particular to a
single user.  (I have redirected followups to comp.mail.misc).

The mail program "mush" (Mail Users' SHell), available from
comp.sources.unix, will do this for you.
-- 
Mark Sirota
 msir_ltd@uhura.cc.rochester.edu (rochester!ur-cc!msir_ltd)
Re: Filtering junk mail
#2979
Author: Pat Barron
Date: Mon, 05 Dec 1988 07:48
12 lines
893 bytes
You can also do this with the "slocal" program that comes with the MH
distribution.  You filter your mail through it in your .forward file,
and it reads a configuration file called ".maildelivery" from your
home directory with instructions on what to do with various pieces
of mail.

--Pat.
-- 
Pat Barron
Internet:  pat@orac.pgh.pa.us  - or -   orac!pat@gateway.sei.cmu.edu
UUCP:  ...!uunet!apexepa!sei!orac!pat  - or -  ...!pitt!darth!orac!pat
Re: Filtering junk mail
#3008
Author: Andrew Findlay
Date: Mon, 05 Dec 1988 15:10
22 lines
1399 bytes
In article <79561@sun.uucp> kuro@sun.UUCP (Teruhiko Kurosaka) writes:
>Does anyone out there knows any way to insert a filter program
>in the sendmail daemon so that a piece of e-mail that meets
>a certain criteria (such as addressed to an alias but not addressed
>to the user directly) goes to a designated folder automatically, or
>just be thrown away?

Look at the 'filter' program that comes with the Elm mailer.
To use it, you just set up your .forward file to pipe all mail through
the filter and it applies a set of rules to each item of mail.

The rules can specify that different things happen to the mail depending on
who it was addressed to, and a number of other things.

Andrew

-- 

---------------------------------------------------------------------
|  From Andrew Findlay at Brunel University, Uxbridge, UB8 3PH, UK  |
|  Andrew.Findlay@brunel.ac.uk          phone: +44 895 74000 x2512  |
---------------------------------------------------------------------
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads