Defcon-1-Logo

           [Home]    [FBSD Articles]    [Scripts Corner]    [Contribute]    [Search]    [FBSD Links]    [Files]

About Us

FreeBSD Articles
  *Hardware
  *Networking
  *Security
  *Software
  *X Windows


Files / Scripts
Newbies Corner
Tech. Talk
Tips and Tricks


FreeBSD Links

Articles in other
Languages :
  *French Articles
  *Spanish Articles

Want to Help ?
 
   Click Here

Email Users5

Search:
 

 


FreeBSD Search:


 

 

Powered-By-Apache-Logo

         Stomping Spam with Sendmail


Many people have problems with spam. The simplest way to avoid it is to never give out your e-mail address to anyone :( or build an access DB.

This will only work with people who use sendmail as their incoming mail server, not mail obtained over a POP3 connection (although this will work with clients such as fetchmail)

Here is a guide to setting up an access DB to stomp spam.


1.) Create the database file.

I suggest creating the file /etc/mail/access or editing this file if it is already there.

2.) Block hosts, address or domains

In this file you need to place the following to
block:

a) domains

domain.com  DENY

b) Hosts

host.domain.com  DENY

c) Email address's

user@domain.com  DENY



An example access file may look like this:-

spammer.com       DENY
spammer2.com      DENY
mail-x.spammers.com   DENY
relay.spammers.com   DENY
jbloggs@spam.com    DENY
jbloggs2@spam.com    DENY

The next step is to tell sendmail to rebuild the access database. The command for this is, as root,

makemap hash access < /etc/mail/access


This will rebuild the access database.
Address's matching this rules will get a message back similar to:

550 - Access Denied...

You have now learned one method of eradicating
spam.

-- Sparc
 

Email Us

ghostrdr@defcon1.org

This site cannot be duplicated without permission

© 1998 - 2010 Defcon1, www.defcon1.org. Copyrights for all materials on this web site are held by the individual authors, artists, photographers or creators. Materials may not be reproduced or otherwise distributed without permission of www.defcon1.org and the content's original author.