LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   About blocking specific email address (https://www.linuxquestions.org/questions/linux-server-73/about-blocking-specific-email-address-510917/)

alucard001 12-15-2006 09:05 PM

About blocking specific email address
 
Hello everyone. There is a problem I would like to ask for all your advices.

Situation:
Assume that there is an account called: myacct on linux which has sendmail, spamassassin and procmail.

Now, this sendmail server will receive email from 2 domains:

ABC.com
DEF.com

So, the following 2 emails are valid:

myacct@abc.com
myacct@def.com

Question:
If I don't want to accept any email from myacct@abc.com, but abc.com should be kept. And I also need to receive email from myacct@def.com.

How can I do this?


I have already tried:

Assume that there is a person who send an email to BOTH addresses listed above:

- Procmail: If I blocked the email address of myacct@abc.com, myacct@def.com will also not be able to receive this email. Rules:

:0 BbHh
* ^To:.*myacct\@abc\.com.*
spam

- spamassassin:

blacklist_to myacct@abc.com

myacct@def.com will also not be able to receive this email.


Can any body give some advices to the above situation?

Thank you very much for all your help!

solnul 12-17-2006 07:48 AM

Maybe something like this (to myacct@abc.com and not to myacct@def)?

:0 BbHh
* ^To:.*myacct\@abc\.com.*
* !^To:.*myacct\@def\.com.*
spam


All times are GMT -5. The time now is 09:40 AM.