<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!-- Start of spam.htm --><!-- delayed after doctype-->
<html>
  <head>
    <link rel="stylesheet" type="text/css" href="../../css2/netwin.css">
    <!--#include virtual="ssi/head_includes.ssi" -->
    <!-- #BeginEditable "Headerstuff"-->
    <title>Spam Guidelines</title>
    <meta name="keywords" content="">
    <meta name="description" content="">
    <meta http-equiv="Content-Type" content="text/html;
      charset=ISO-8859-1">
    <!-- #EndEditable -->
  </head>
  <body class="s_body">
    <!--#include virtual="ssi/page_start.ssi" -->
    <!--#include virtual="ssi/columns_start.ssi" -->
    <!--#include virtual="ssi/column_L2C2_left.ssi" -->
    <!--#include virtual="ssi/document_index.ssi" -->
    <!--#include virtual="ssi/column_end.ssi" -->
    <!--#include virtual="ssi/column_L2C2_content.ssi" -->
    <!-- #BeginEditable "Body" -->
    <script language="JavaScript"> search_details('Search SurgeMail Manual:','http://netwinsite.com/surgemail/help'); </script>
    <script language="JavaScript"> display_crumbs_doc(['Home','Documentation','SurgeMail Help Index','Spam Prevention'],3); </script>
    <script language="JavaScript"> index_select('idx_spam.htm'); </script>
    <h1>Spam Prevention using SurgeMail Features</h1>
    <ul>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="#easy">How to enable SPAM handling</a></font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="#how">How it works</a> (in brief)</font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="myrbl.htm">Technical details on how SurgeMail stops
            spam</a></font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="#settings">List of recommended settings with notes</a></font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="#me">Settings to stop spam of the form from=to (where
            the sender pretends to be the recipient)</a></font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="#hackers">Stop hackers from sending spam from your
            server!</a><br>
        </font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><a
            href="#faq">Frequently Asked Questions</a></font></li>
    </ul>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">NOTE:
        Turning on the recommended settings WILL NOT block email from
        servers without SPF. This seems to be the number one confusion.
        Many customers are reluctant to turn on the settings recommeded
        as they fear their server will then bounce all email from badly
        configured mail systems, this is NOT the case, please try the
        recommended settings as a starting point!!</font></p>
    <h2><a name="how"></a>How it works</h2>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Spam
        prevention has gone through many changes over the last few
        years, initially people tried to filter spam based on the
        'content' although this worked well initially it soon started to
        fail as spammers adjusted their spam. The focus of successful
        spam prevention is based on a multi pronged attack, where the
        'source' of the message is verified in various ways, and the
        content of the message is checked, and then finally the
        'friends' system catches and automatically deals with any
        messages that still get through while it also automatically
        white lists known associates.</font></p>
    <p>For more information see the <a href="#details">detailed
        technical description</a> of how SurgeMail stops spam when
      correctly configured.</p>
    <h2><a name="easy"></a>How to enable SPAM handling</h2>
    <ol>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Upgrade

          to the latest stable release</font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Press

          the 'config checker' button in the web admin interface and
          turn on the settings it suggests</font></li>
      <li> Either set G_FRIENDS_DEFAULT_MODE "smite" or "silent" or
        "list" </li>
      <ul>
        <li>smite = If message is placed in 'spam' folder tell 'sender'
          and give them a url to allow delivery of their message</li>
        <li>silent = If message is placed in 'spam folder do not tell
          the sender</li>
        <li>list = Maintain friends lists for whitisting but deliver all
          mail (including spam) to the users inbox</li>
      </ul>
      <li>Tell all users to individually turn on/set/adjust their
        friends options in the user self admin settings. </li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Advise

          your users how to turn on/off user configurable options (this
          is done in the user self admin pages or via options in
          surgeweb)</font><font face="Verdana, Arial, Helvetica,
          sans-serif" size="2"><br>
        </font></li>
    </ol>
    <h2><a name="settings"></a>List of recommended settings with notes</h2>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_orbs_list

        name="zen.spamhaus.org" action="stamp" stamp="zen.spamhaus.org ,
        ip= "</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting tells surgemail to check the IP address with an RBL
          service (in this case spamhaus) This setting improves the spam
          scoring features.</font> Please check <a href="rbl.htm">http://www.netwinsite.com/surgemail/help/rbl.htm</a>
        for more infomation on RBL's. </p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_verify_mx_skip

        "10.0.0.2" </font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting should list your other MX hosts (low priority mx
          host). However our general recommendation is to REMOVE low
          priority mx hosts entirely as they serve no useful purpose and
          will tend to allow spam through your system.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spam_allow

        "10.2.192.98-117"</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting lets you list the ip addresses of known trusted hosts.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spam_subject

        "4"</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting adds **** to the subject of messages that score more
          than '4'.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spam_userconfig

        "TRUE"</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting lets the users change their own spam settings.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spam_internal

        "true" ("Enable ASpam" setting in user interface)<br>
      </font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          turns on the aspam scoring system.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">
        g_spam_catcher "fred@your.domain"<br>
      </font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting is used to train the aspam filter with spam that comes
          to special email addresses on your system, place these email
          addresses on your web pages so that spammers will accidentally
          train your system for you :-)</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_url_enable

        "true"<br>
      </font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          adds some url scoring using a netwin provided database that is
          updated every few hours, you should also use SURBL as well.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_vanish_bad_bounces

        "TRUE"<br>
      </font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          gets rid of bounces that didn't originate from your server.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_verify_smtp

        "TRUE" (Probably not needed when using spf)</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting checks if the connecting smtp server is open on port
          25. The spam scoring is adjusted if the test fails.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spf_mode

        "strict" <b>(absolutely essential!!!)</b> <br>
        g_spam_block "true"<b> (absolutely essential!!!)</b></font><font
        face="Verdana, Arial, Helvetica, sans-serif" size="2"><br>
      </font><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spam_allow_known

        "true" (this allows more spam through but cuts down on
        rejections)<br>
        g_spam_grey_dflt "false"<br>
        g_spam_grey_dflt_bad "true"<br>
        g_spam_grey_bounce "10" (explained below)<br>
      </font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">These

          settings turn on SPF see http://netwinsite.com/spf.htm. In
          addition the g_spam_block setting makes it actually block all
          the spam that fails spf tests. However to reduce impact the
          grey settings mean that failures are grey listed, and only
          fully blocked if grey listing fails, or if too many messages
          arrive within a short time period (1 message)</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_surbl

        name="multi.surbl.org"
        stamp="sc.surbl.org,ws.surbl.org,phishing,ob.surbl.org,ab.surbl.org,jp"</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          setting is critical to spam detection, the surbl database is
          used to detect urls that spammers are trying to promote.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">g_spam_grey_bounce

        "10"</font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">
          This setting lets surgemail bounce a message that looks
          'spammy' if it failed some spf tests but got past the grey
          listing mechanism. This cuts down on spam but does often
          bounce real emails (it uses an allow bounce so the sender can
          fix it)</font></p>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">It's

          probably better for individual users to use their friends
          settings instead. </font></p>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This

          used to default to 3 and still is on any version prior to
          "SurgeMail Version 3.8". The new default value is 10 which
          lets more spam through, but reduces accidental bounces. We now
          recommend a value of '10' unless you are happy with some real
          legit email bouncing. </font></p>
    </blockquote>
    <h3>Settings you SHOULD REMOVE.</h3>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">We
          often find problems occur when non standard settings or
          obsolete settings have been turned on, here are the main
          culprits you should remove. These will break the normal spam
          prevention occuring and or cause massive complaints from users
          due to bounces. </font></p>
      <blockquote>
        <p><font color="#FF0000" face="Courier New, Courier, mono">(remove)

            g_spf_default_noblock "TRUE"<br>
            (remove) g_spam_grey "TRUE"<br>
            (remove) g_spam_grey_dflt "TRUE" (optional) <br>
            (remove) g_spam_allow_disable "TRUE"</font></p>
        <p><font color="#FF0000" face="Courier New, Courier, mono">(remove)

            g_badfrom_check "TRUE"<br>
          </font><font color="#FF0000" face="Courier New, Courier, mono">(remove)

            g_badfrom_stamp "TRUE"</font></p>
        <p>&nbsp;</p>
      </blockquote>
    </blockquote>
    <h2><a name="faq"></a>Frequently Asked Questions FAQ</h2>
    <h3>Can I avoid backscatter from friends?</h3>
    <p>Yes use this setting </p>
    <p>G_FRIENDS_CHECK_SPF "true"</p>
    <h3>What are the recommended best practise techniques to avoid spam
      on my server?</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">See
        the list of settings above, primarily you want SURBL, RBL's and
        SPF (in strict mode with the g_spam_block turned on). Also avoid
        using front end filter systems as these will prevent the best
        spam features in surgemail working. And suggest users turn on
        'friends' with a friends bounce level of about 4. </font></p>
    <h3>Doesn't SPF rely on the senders creating spf records ? </h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">No,
        in strict mode surgemail makes up an spf record for all incoming
        domains so it works for everyone. When the made up spf record
        fails (which is rare) surgemail then provides other checks and
        mechanisms so real email can still get through. </font></p>
    <h3>Is there something else I should be doing to prevent spam, why
      do I get so much when other people get none? </h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Although

        these mechanisms can stop almost all spam, there is another way
        to get rid of spam, and if you use it, then you can adjust the
        filters to be very 'forgiving' so that real messages are never
        caught by them. So here's the trick, the BEST way to avoid spam,
        is to change your email address! and keep your new email address
        private:</font></p>
    <ul>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Never

          put an email address on a web page, use a form instead (our
          free <a href="/easyform">easyform</a> product for example)</font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Never

          post to a public news group except through a system that hides
          email addresses (See <a
            href="http://netwinsite.com/surgenews">SurgeNews</a>)</font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Never

          join a mailing list. Instead use an RSS feed (See <a
            href="http://netwinsite.com/surgenews">SurgeNews</a>), or a
          special second email account.</font></li>
    </ul>
    <h3>What are the likely side effects and implications of using these
      measures?</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">You
        will bounce some real mail messages and because some people
        don't read the bounce messages they will actually fail to
        respond correctly to get past the automated spam prevention. The
        above settings only require respones from about 1-2% of people
        so most mail gets through without any trouble, but a small
        percentage will be bounced and if the user sending doesn't
        respond then the message will fail to be delivered. This results
        in a loss of about 0.1% of messages, much lower than letting
        humans do the filtering, but still not perfect.</font></p>
    <h3> How do I measure how effective these techniques are? (my
      manager needs a report to justify costs)</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">In
        the advanced status section in surgemail there is a 'spam'
        section, this has figures on the various filter hit rates, it's
        a little hard to interpret but it gives a fairly good idea of
        how much spam has been blocked.</font></p>
    <h3>How are false positives handled? Each email is important to me,
      and I must avoid false positives at all costs, how can I monitor
      email identified as spam until I am confident that the system has
      no / minimal false positives?</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">With
        SPF and friends false positives result in some form of bounce,
        the user sending the message must then respond to the bounce to
        get their original message delivered. (With SPF failures they
        must resend, with Friends they need not). You will only loose
        messages when the person sending to you does not read the
        bounces. From the user web interface you can search through all
        the bounces manually and release messages pending confirmation
        via friends, and fix SPF failures.</font></p>
    <h3>How can spam that was not caught be submitted (by users)? and
      how do users/admin get feedback that their submissions are
      actually doing something?</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">You
        or any user can send messages to isspam@your.domain or
        notspam@your.domain, this will improve the scoring in future.
        From the managers web admin pages for spam you can also paste in
        a message and get it analyzed, or trained. This process should
        not be over emphasized, it is good for fine tuning the filters
        slightly but it is not at all critical that you submit every
        failed message or every false positive. The messages can be sent
        as attachments or redirects, it doesn't matter much which is
        done as the system is forgiving. If a messages is sent to the
        wrong training address, just resend it to the other address to
        nullify the training.</font></p>
    <h3>How should I as a user configure my spam controls on my email.
      There seem to be several ways of configuring filters + friends +
      spam/spf etc to work together. Why should / whould I not use a
      particular combination. Are there particular things that I
      probably should not configure?</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">This
        is very important, if you get 'lots' of spam and want to get
        none.</font></p>
    <ul>
      <ul>
        <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Set

            the SPF setting to BLOCK</font></li>
        <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Set

            friends mode to anything above '2' stars</font></li>
      </ul>
    </ul>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">If
        you get a small amount of spam but want to get rid of 'most' of
        it, without much risk of ever bouncing a real message:</font></p>
    <ul>
      <ul>
        <li><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Set

            friends mode to anything above '6' stars </font></li>
      </ul>
    </ul>
    <h3>Are there any significant performance effects? (on 100 / 5000 /
      100000 user system) Both in increased load that these measures put
      on system resources (disk / cpu / open channels / resposiveness
      etc) and reduced load by not having to deal with spam. How can I
      measure these effects?</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Not
        really, the spam system in SurgeMail is very efficient and the
        SPF features and vanish bad bounce settings do reduce real load
        on heavily spammed servers, so the spam prevention tends to
        result in a slight performance improvement, and reduced network
        bandwidth usage. </font></p>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">We do
        STRONGLY recommend the use of the AVAST virus scanner product as
        it is enormously more efficient than some of the free unix
        command line scanning utilities that you can use with SurgeMail
        (mainly because it does not get activated for each scan as it's
        part of the server)</font></p>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Also
        using external spam checking systems (which you can do if you
        really want to) is also strongly discouraged, these generally
        won't increase your filtering accuracy but will badly affect
        performance. </font></p>
    <h3>I want to counter some rules in ASPAM - for example NakedCR.</h3>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">ASPAM's

        filter rules are stored in aspam_mfilter.txt, you cannot edit
        this file as it is updated regulary so any changes you make will
        be overwritten. You need to edit the file local.rul where you
        can add your own rules.</font></p>
    <pre>     if (isin("X-NakedCr","body")) then
          call spamdetect(0.1,"NakedCR")
     end if</pre>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">In
        general, look through aspam_mfilter.txt find the rule and then
        write the same rule in local.rul but with a negative score to
        cancel the scoring in aspam_mfiler.rul. The string/reason in
        local.rul must be _exactly_ the same as the string in
        aspam_mfilter.rul for the rule to overide the first one. </font></p>
    <h2>New settings that we hope to make recommended in future. </h2>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">These

          settings are typically new settings only available in the <b>latest

            beta builds</b>, and<b> may be unstable,</b> but once stable
          we expect to become recommended settings so you might want to
          experiment with these.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><b>g_domainkeys_check

          "true" </b></font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Checks

          incoming email for for signatures and if found verify, this
          will help avoid bounces from domains that use domainkeys
          instead of spf. </font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><b>g_domainkeys_sign

          "true" (see note below)</b></font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Use
          the web admin to create your finger print and then save in
          your dns first.</font></p>
    </blockquote>
    <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2"><b>g_spam_share

          "true" </b></font></p>
    <blockquote>
      <p><font face="Verdana, Arial, Helvetica, sans-serif" size="2">Use
          and contribute to shared whitelist database via netwinsite.com
          to avoid spf bounces for well known sites that are not
          spammers but fail spf tests.</font></p>
    </blockquote>
    <h2><a name="external"></a>Integrating external SPAM filters</h2>
    <p><font face="Verdana, Arial, Helvetica, sans-serif">You can in
        addition to the normal surgemail spam features run an external
        spam filter which is a command line program that examines the
        message then returns non zero numbers if it thinks the message
        is spam. This can then contribute to the SurgeMail score for
        that message.</font></p>
    <p><font face="Verdana, Arial, Helvetica, sans-serif">We recommend
        this external filter, it's a reasonable price and seems to work
        reasonably well: http://www.armresearch.com/message-sniffer/ we
        are keen to hear feedback from anyone using filters like this.</font></p>
    <p><font face="Verdana, Arial, Helvetica, sans-serif">These settings
        require SurgeMail 3.8-20 or later, email support@netwinsite.com
        if you need this build to try this new feature.</font></p>
    <h4><font face="Verdana, Arial, Helvetica, sans-serif">Surgemail.ini
        setting:</font></h4>
    <p><font face="Verdana, Arial, Helvetica, sans-serif">Replace the
        weird code with your temporary license that they provide and
        correct the path to the binary.</font></p>
    <pre>	G_SPAM_CMD "c:\surgemail\snfrv2r3.exe xnk05x5vmipeaof7 $FILE$"</pre>
    <p><font face="Verdana, Arial, Helvetica, sans-serif">Add some rules
        to your local.rul file to process the resulting header:</font></p>
    <pre>	if (isin("X-SpamCmd","Is Spam")) then
		call spamdetect(5,"ArmResearch")
	end if<br>	if (isin("X-SpamCmd","Not Spam")) then
		call spamdetect(-3,"ArmResearch")
	end if<br></pre>
    <h2><a name="me"></a>Forgeries of the form From=To</h2>
    <p><font face="Verdana, Arial, Helvetica, sans-serif">There has
        recently been an increase in spam where the From and To headers
        are set to be the same as the user. To block this type of spam
        ensure you have done the following steps</font></p>
    <ul>
      <li><font face="Verdana, Arial, Helvetica, sans-serif">Install the
          latest version of SurgeMail (3.9h-61 or later) </font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif">Turn on the
          Recommended settings using the web admin tool config wizard. </font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif">Set<b>
            g_from_stamp "true" and g_from_noforgeme "true"</b></font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif">We also
          recommend you have an SPF entry for your domain in your dns
          server, and set <b>g_spf_enforce_local "true"</b> </font></li>
      <li><font face="Verdana, Arial, Helvetica, sans-serif">In version
          4.0b-19 and later you can use the command "tellmail
          scan_friends" to detect users who have accidentally added
          themselves to their own list of friends (this is not possible
          to do in new versions but many users did it before we made it
          impossible). In addition it's possible to remove those entries
          with the 'repair' switch for that command. </font></li>
    </ul>
    <h2>Optional settings to stop more spam...</h2>
    <p>Some of these are a bit 'strict' so use with caution depending on
      your tastes...</p>
    <p>&nbsp;</p>
    <p>You may wish to try this setting, it will black list any ip
      address that is the source of a isspam training event for an hour
      or so, this is most useful with your catcher addresses as it means
      any spammer who sends to your spam catcher will find themselves
      blocked from sending any email to your server for an hour or so.
      You may need a whitelist for a few large sites to avoid issues
      with deleted users causing a large mail server to get blocked.
      Hence the g_black_white setting given as an example...</p>
    <p>&nbsp;</p>
    <blockquote>
      <p><b>g_black_isspam "true"</b></p>
      <p><b>g_black_white "1.2.3.*,*ebay.com"</b></p>
      <p>&nbsp;</p>
    </blockquote>
    <p>&nbsp;</p>
    <p>You can tell surgemail to try and guess the language of each
      message, you can then set for any account in your spam settings
      the langauge you expect, if you get messages that are not in your
      language (e.g. english) then the message will be assumed to be
      spam until proven otherwise (So it goes to your friends pending
      folder), this will reduce spam significantly for those of us who
      really only speak one language :-). Be warned it does not always
      guess correctly, and is more likely to be wrong with non english
      messages.</p>
    <blockquote>
      <p><b>g_spam_lang "true"</b></p>
      <p>&nbsp;<br>
      </p>
    </blockquote>
    <h2><br>
    </h2>
    <h2><a name="hackers"></a>Stop hackers from using your server to
      send spam</h2>
    Hackers are now probing mail servers all the time to find email
    accounts with 'easy' passwords, they are probably already probing
    your server.&nbsp; They will break in if you have any accounts with
    simple passwords.&nbsp; So on a large server its not a question of
    'if' your server will be hacked, it's really more a question of
    when.&nbsp; You need to make it harder for the hackers, and you need
    to be ready to detect the locally hacked account and shut it down
    quickly before your reputation suffers! <br>
    <br>
    20-30% of users who have their accounts hacked 'won't change their
    own passwords even once they are told by someone that they have been
    hacked.&nbsp; So don't expect your users to take action themselves
    :-) <br>
    <br>
    <h3> Here are some things you might consider to help stop this
      occurring, and to help identify it when it does occur.</h3>
    <br>
    # Find any local accounts with really really obvious passwords! <br>
    tellmail test_weak<br>
    <br>
    # Login guesses per IP before it is automatically and permenently
    locked out.&nbsp;&nbsp; Use tellmail unlock ip.address to fix...<br>
    G_HACKER_MAX "10"&nbsp;&nbsp;&nbsp; <br>
    <br>
    # If hacker attempts to login to one of these then the ip is
    instantly locked out.&nbsp; (Don't use accounts that exist)<br>
    G_HACKER_POISON "root@*,administrator@*" <br>
    <br>
    # Only allow smtp logins if the user has previously logged in via
    imap/pop from the same address<br>
    G_SAFE_SMTP "true"<br>
    &nbsp;<br>
    # Max messages an authenticated user can send per 30 minutes, e.g.
    5000<br>
    G_SPAM_USER_MAX "2000"<br>
    <br>
    # Max outgoing messages per ipaddress/return path pair, 30 minutes,
    e.g. 5000<br>
    G_SPAM_FROM_MAX "2000" <br>
    <br>
    # Detect local users sending 'spam like' email and send a report to
    the manager.<br>
    G_OUTGOING_N "5"<br>
    <br>
    # White list for people you know send mail that looks a bit dodgy.<br>
    G_OUTGOING_WHITE "bob@here.com,1.2.3.4"<br>
    <br>
    <br>
    # send manager an&nbsp; email if a local user sends more than 300
    message in a day...<br>
    G_USER_SEND_WARNING "300" <br>
    g_user_send_ip "300"<br>
    <br>
    <blockquote> </blockquote>
    <p><br>
    </p>
    <hr style="width: 100%; height: 2px;"><br>
    One other method to protect your server is to make the login
    username different from the email address.&nbsp; You can do this on
    a per domain level, lets say you have a domain MYDOMAIN.COM and you
    want the users to login with username=JOHN@SECRET.MYDOMAIN.COM<br>
    <br>
    &nbsp;&nbsp;&nbsp; g_from_rewrite was="*@secret.mydomain.com"
    to="%1@mydomain.com"<br>
    &nbsp;&nbsp;&nbsp; g_from_rewrite_header "true"<br>
    &nbsp;&nbsp;&nbsp; g_from_rewrite_sender "true"<br>
    <br>
    vdomain name="mydomain.com"<br>
    &nbsp;&nbsp;&nbsp; security_suffix "secret.mydomain.com"<br>
    &nbsp;&nbsp;&nbsp; ...<br>
    <p><br>
    </p>
    <blockquote>
      <p> <br>
      </p>
      <p>&nbsp;</p>
    </blockquote>
    <!-- #EndEditable -->
  </body>
</html>

<!-- End of spam.htm -->

