Date: Sat, 3 May 1997 19:46:17 +0800 (WST) From: Adrian Chadd <adrian@obiwan.psinet.net.au> To: freebsd-hackers@freebsd.org Subject: Antispam sendmail.cf modifications.. Message-ID: <Pine.BSF.3.95q.970503192455.9973A-100000@obiwan.psinet.net.au>
index | next in thread | raw e-mail
This stuff is just repeats off webpages and usenet postings, but I suppose
nothing will happen unless someone does something. :)
The diffs from the standard sendmail.cf file are as follows :
--- /etc/sendmail.cf Sat May 3 19:19:09 1997
+++ /etc/sendmail.cf.back Sat May 3 18:55:44 1997
@@ -85,21 +85,6 @@
# ... define this only if sendmail cannot automatically determine your domain
#Dj$w.Foo.COM
-# Both these files are basic text files, one host or user@host per line
-# a list of known spammers, user@host form one per line
-F{Spammer}/etc/sendmail/spammers
-
-# A list of domains to completely block, one per line
-F{SpamDomains}/etc/sendmail/spamdomains
-
-Kdequote dequote
-# Localdomains is a plaintext list of domains we accept mail for, including
-# virtual domains
-F{LocalDomains}/etc/sendmail/virtdomains
-# Contains a plaintext list of IPs we will relay mail for, can be X.Y.Z to
-# cover a whole class C..
-F{LocalNetworks}/etc/sendmail/localnetworks
-
CP.
@@ -929,49 +914,3 @@
R$+ $: $>61 $1
R$+ $: $>93 $1
-
-
-
-# blocking of spammers at MAIL From:
-Scheck_mail
-R<$={Spammer}> $#error $@ 5.7.1 $: "571 We don't accept junk mail"
-R$* $: $>3 $1
-R$*<@$={SpamDomains}.>$* $#error $@ 5.7.1 $: "571 We don't accept junk mail from your domain"
-R$*<@$={SpamDomains}>$* $#error $@ 5.7.1 $: "571 We don't accept junk mail from your domain"
-R$={Spammer} $#error $@ 5.7.1 $: "571 We don't accept junk mail from your domain"
-
-
-
-#
-# check_rcpt
-#
-Scheck_rcpt
-
-# mail terminating locally is ok
-R$*$={LocalDomains}$* $@ OK
-
-# adding the client's domain name...
-R$* $: $(dequote "" $&{client_name} $) $| $1
-
-# directly invoked (no client name) is ok
-R $| $* $@ OK
-
-# we will relay mail from clients in our own domain
-R$*$={LocalDomains}$* $| $* $@ OK
-
-# adding the client's ip number...
-R$* $: $(dequote "" $&{client_addr} $) $| $1
-
-# directly invoked (no ip address) is ok
-R0 $| $* $| $* $@ OK
-
-# we will relay all mail from clients on our own networks
-R$*$={LocalNetworks}$* $| $* $| $* $@ OK
-
-# or from localhost
-R$*127.0.0.1$* $| $* $| $* $@
-
-# anything else is bogus
-R$* $#error $: "550 Relay Denied"
-
-
*** End
You have 4 files in /etc/sendmail/ :
localnetworks: IPs which you will relay mail from - eg the IP ranges of
your dialups. can be set as XXX.XXX.XXX to allow the
C-class.
virtdomains: Domains which you accept mail for - including virtual
ones.
spamdomains: Domains you want to reject for spamming
spammers: u@h 's that you want to reject for spamming.
Testing show that they work, my only gripe is that (apparently) if I have
cyberpromo.com in spamdomains, it will reject mail from
luser@cyberpromo.com, but not luser@something.cyberpromo.com. That would
be a better feature, if someone wants to modify my patch for that to work.
Also, I wouldn't mind the modification that makes sendmail refuse MAIL
FROM:s with invalid domain names... I'll go out and find it but if anyone
else has it, feel free to email it here.
Cya
--
Adrian Chadd | UNIX, MS-DOS and Windows ...
<adrian@psinet.net.au> | (also known as the Good, the bad and the
| ugly..)
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.95q.970503192455.9973A-100000>
