Hi,

I am running a mail server for a community, my server receives lot of spam, which results in thousands of emails in mail queue as the senders use dummy emails.

I am using Sendmail on Linux Red Hat 7.2, want to know how to stop spam strom on my server, thanks.

    10 days later

    Hello,
    I have used spamassassin: http://spamassassin.org/
    At first, you have to install it.
    After that, you have to have procmail on your server, else you have to find another way...
    But if you have it installed, you have to locate the system-wide procmailrc and insert the following code:
    #############BEGIN##################

    SpamAssassin sample procmailrc

    #

    Pipe the mail through spamassassin (replace 'spamassassin' with 'spamc'

    if you use the spamc/spamd combination)

    #

    The condition line ensures that only messages smaller than 250 kB

    (250 * 1024 = 256000 bytes) are processed by SpamAssassin. Most spam

    isn't bigger than a few k and working with big messages can bring

    SpamAssassin to its knees.

    #

    The lock file ensures that only 1 spamassassin invocation happens

    at 1 time, to keep the load down.

    #
    :0fw: spamassassin.lock
    * < 256000
    | spamassassin
    ##################END###############

    Then, every mail is passed through spamassassin.
    Now you can configure spamassassin in /etc/mail/spamassassin/local.cf .
    I have inserted the following there:

    required_hits 6.0
    rewrite_subject 1
    subject_tag *SPAM: score HITS

    Every mail gets scored with spamassassin... If the score is higher as required_hits, the mail is marked as spam...
    The other config options assure that every spam-mail gets a SPAM: score in its subject...

    Hope that helps....

    Sebastian

      Write a Reply...