Delete email starting with mail@, uucp@
Julian Field
MailScanner at ecs.soton.ac.uk
Thu Mar 27 20:56:25 GMT 2008
David Jourard wrote:
> Matt Kettler wrote:
>> David Jourard wrote:
>>> Hi,
>>>
>>> I just upgraded MailScanner from an older version I had running.
>>>
>>> I had a bunch of rules I setup in spam.blacklist.rules
>>>
>>> Example:
>>>
>>> FromOrTo: root at clientdomain.com yes
>>> FromOrTo: mail at clientdomain.com yes
>>> FromOrTo: uucp at clientdomain.com yes
>>> FromOrTo: info at clientdomain.com yes
>>>
>>> They were being deleted.
>>>
>>> They are now getting delivered.
>>>
>>> What parameters do I need to set so that they get deleted.
>>
>> Any reason you're doing this at the MailScanner layer?
> Ignorance
>
>>
>> If you're just going to delete it, save your network the bandwidth of
>> receiving it and just 550 it at the MTA layer.
>
> This sounds like a wonderful solution.
>>
>> For example, in sendmail you'd edit /etc/mail/access and add:
>> root at clientdomain.com REJECT
>> mail at clientdomain.com REJECT
>> uucp at clientdomain.com REJECT
>> info at clientdomain.com REJECT
>>
>> Then run make in /etc/mail/ directory to rebuild access.db from the
>> access text file.
> What command do I use. Is it makemap hash (like I've been doing for
> virtualusertable).
cd /etc/mail
make -n
That will show you what it's going to do, without actually doing it.
Make sure it prints a command that looks like it will rebuild the access db.
make
That will actually do it.
>
> Do I need to restart MailScanner (which also restarts sendmail).
Easy enough to test. Try
sendmail -bv info at clientdomain.com
and see what it says it will do with it. If it looks like it's going to
try to deliver it, then do a quick
service MailScanner restart
I don't *think* you need to, but someone will surely correct me if I'm
wrong.
Jules
--
Julian Field MEng CITP CEng
www.MailScanner.info
Buy the MailScanner book at www.MailScanner.info/store
MailScanner customisation, or any advanced system administration help?
Contact me at Jules at Jules.FM
PGP footprint: EE81 D763 3DB0 0BFD E1DC 7222 11F6 5947 1415 B654
PGP public key: http://www.jules.fm/julesfm.asc
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
More information about the MailScanner
mailing list