# SpamAssassin rules file: network tests
#
# Please don't modify this file as your changes will be overwritten with
# the next update. Use /etc/mail/spamassassin/local.cf instead.
# See 'perldoc Mail::SpamAssassin::Conf' for details.
#
# Note: body tests are run with long lines, so be sure to limit the
# size of searches; use /.{0,30}/ instead of /.*/ to avoid huge
# search times.
#
# Note: If you are adding a rule which looks for a phrase in the body
# (as most of them do), please add it to rules/20_phrases.cf instead.
#
# <@LICENSE>
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements.  See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to you under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License.  You may obtain a copy of the License at:
# 
#     http://www.apache.org/licenses/LICENSE-2.0
# 
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# </@LICENSE>
#
###########################################################################

require_version 3.002005

# ---------------------------------------------------------------------------
# Message digest tests

# bug 2220. nice results
meta DIGEST_MULTIPLE		RAZOR2_CHECK + DCC_CHECK + PYZOR_CHECK > 1
describe DIGEST_MULTIPLE	Message hits more than one network digest check
tflags DIGEST_MULTIPLE		net
#reuse DIGEST_MULTIPLE

###########################################################################

ifplugin Mail::SpamAssassin::Plugin::DNSEval

header NO_DNS_FOR_FROM		eval:check_dns_sender()
describe NO_DNS_FOR_FROM	Envelope sender has no MX or A DNS records
tflags NO_DNS_FOR_FROM		net
#reuse NO_DNS_FOR_FROM

endif

###########################################################################

ifplugin Mail::SpamAssassin::Plugin::HeaderEval

# this variant uses a DNS reverse lookup.  so now we can use a version
# of this test without a net connection (ROUND_THE_WORLD_LOCAL)
header ROUND_THE_WORLD		eval:check_for_round_the_world_received_revdns()
describe ROUND_THE_WORLD	Received: says mail sent around the world (DNS)
tflags ROUND_THE_WORLD		net
#reuse ROUND_THE_WORLD

endif
