Docs: add note on DKIM verify disable
[exim.git] / test / scripts / 4000-scanning / 4003
index 49d331bf1b3a338e3a68e3fc8de9c1fa456b65c3..1f4917d9b2f6dd3ef101d3b853279f5ce58aeafa 100644 (file)
-# content scan interface: fsecure
-# also testing alternate list separator for malware= args
-#
-server DIR/eximdir/fsec_sock
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<SCAN
->LF>random ignored line
->LF>random ignored line 2
->LF>OK Scan ok.
+# content scan interface: spamassassin
+#
+# The spooled file for scanning includes the test-runner's user name
+# hence size varies.  Munge that.
+munge scanfile_size
+#
+#
+# A good-comms test, returning not-spam.
+# (we could use a second one that returns is-spam...)
+server 7833
+<REPORT SPAMC
+<User:
+<Content-length:
+<
+<From
+<X-Envelope-From
+<X-Envelope-To
+<Received:
+<      by
+<      (envelope
+<      id
+<      for
+<      
+<Content-type: text/plain
+<Message-Id:
+<From:
+<Date:
+<
+<test
+>SPAMD/1.1 0 EX_OK
+>Spam: False ; 4.5 / 5.0
+>
+>Spam detection software, running on the system "demo",
+>has NOT identified this incoming email as spam.  The original
+>message has been attached to this so you can view it or label
+>similar future email.  If you have any questions, see
+>@@CONTACT_ADDRESS@@ for details.
+>
+>Content preview:  test [...]
+>
+>Content analysis details:   (4.5 points, 5.0 required)
+>
+> pts rule name              description
+>---- ---------------------- --------------------------------------------------
+>-1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
+> 1.2 MISSING_HEADERS        Missing To: header
+> 1.0 MISSING_FROM           Missing From: header
+> 1.8 MISSING_SUBJECT        Missing Subject: header
+> 1.4 MISSING_DATE           Missing Date: header
+> 0.1 MISSING_MID            Missing Message-Id: header
+>
 *eof
 ****
-#
-#
-#
-exim -odi -bs -DOPT=
+exim -odi -oMt fromuser -bs
 ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
 rcpt to:<userx@test.ex>
 data
-Date: Fri, 17 Dec 2004 14:35:01 +0100
-Subject: message should be accepted
+Content-type: text/plain
 
+test
 .
 quit
 ****
 #
 #
 #
-server DIR/eximdir/fsec_sock
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<SCAN
->LF>xxxINFECTED        blah    VNAME   blah
->LF>OK Scan ok.
+#
+# Server spec line with timeout option, not exercised
+# (could we cut down the massive content?)
+server 7833
+<REPORT SPAMC
+<User:
+<Content-length:
+<
+<From
+<X-Envelope-From
+<X-Envelope-To
+<Received:
+<      by
+<      (envelope
+<      id
+<      for
+<      
+<Content-type: text/plain
+<Message-Id:
+<From:
+<Date:
+<
+<test
+>SPAMD/1.1 0 EX_OK
+>Spam: False ; 4.5 / 5.0
+>
+>Spam detection software, running on the system "demo",
+>has NOT identified this incoming email as spam.  The original
+>message has been attached to this so you can view it or label
+>similar future email.  If you have any questions, see
+>@@CONTACT_ADDRESS@@ for details.
+>
+>Content preview:  test [...]
+>
+>Content analysis details:   (4.5 points, 5.0 required)
+>
+> pts rule name              description
+>---- ---------------------- --------------------------------------------------
+>-1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
+> 1.2 MISSING_HEADERS        Missing To: header
+> 1.0 MISSING_FROM           Missing From: header
+> 1.8 MISSING_SUBJECT        Missing Subject: header
+> 1.4 MISSING_DATE           Missing Date: header
+> 0.1 MISSING_MID            Missing Message-Id: header
+>
 *eof
 ****
-#
-#
-#
-exim -odi -bs -DOPT=
+exim -odi -oMt fromuser -bs -DOPT='127.0.0.1 7833 retry=10s'
 ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
 rcpt to:<userx@test.ex>
 data
-Date: Fri, 17 Dec 2004 14:35:01 +0100
-Subject: message should be rejected
+Content-type: text/plain
 
+test
 .
 quit
 ****
 #
 #
 #
-server DIR/eximdir/fsec_sock
-*sleep 3
+# Server spec line with timeout option, exercised
+server -i 2 7833
+<REPORT SPAMC
+<User:
+<Content-length:
+<
+<From
+<X-Envelope-From
+<X-Envelope-To
+<Received:
+<      by
+<      (envelope
+<      id
+<      for
+<      
+<Content-type: text/plain
+<Message-Id:
+<From:
+<Date:
+<
+<test
+>SPAMD/1.1 0 EX_OK
+>Spam: False ; 4.5 / 5.0
+>
+>Spam detection software, running on the system "demo",
+>has NOT identified this incoming email as spam.  The original
+>message has been attached to this so you can view it or label
+>similar future email.  If you have any questions, see
+>@@CONTACT_ADDRESS@@ for details.
+>
+>Content preview:  test [...]
+>
+>Content analysis details:   (4.5 points, 5.0 required)
+>
+> pts rule name              description
+>---- ---------------------- --------------------------------------------------
+>-1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
+> 1.2 MISSING_HEADERS        Missing To: header
+> 1.0 MISSING_FROM           Missing From: header
+> 1.8 MISSING_SUBJECT        Missing Subject: header
+> 1.4 MISSING_DATE           Missing Date: header
+> 0.1 MISSING_MID            Missing Message-Id: header
+>
+*eof
 ****
-#
-#
-#
-exim -odi -bs -DOPT=";tmo=2s"
+exim -odi -oMt fromuser -bs -DOPT='127.0.0.1 7833 retry=4s'
 ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
 rcpt to:<userx@test.ex>
 data
-Date: Fri, 17 Dec 2004 14:35:01 +0100
-Subject: message should be tmp-rejected due to timeout
+Content-type: text/plain
 
+test
 .
 quit
 ****
 #
 #
 #
-server DIR/eximdir/fsec_sock
-*sleep 3
+# Multiple servers, prioritised, with timeout spec; first one fails
+# List separator changed
+server 7833
+<REPORT SPAMC
+<User:
+<Content-length:
+<
+<From
+<X-Envelope-From
+<X-Envelope-To
+<Received:
+<      by
+<      (envelope
+<      id
+<      for
+<      
+<Content-type: text/plain
+<Message-Id:
+<From:
+<Date:
+<
+<test
+>SPAMD/1.1 0 EX_OK
+>Spam: False ; 4.5 / 5.0
+>
+>Spam detection software, running on the system "demo",
+>has NOT identified this incoming email as spam.  The original
+>message has been attached to this so you can view it or label
+>similar future email.  If you have any questions, see
+>@@CONTACT_ADDRESS@@ for details.
+>
+>Content preview:  test [...]
+>
+>Content analysis details:   (4.5 points, 5.0 required)
+>
+> pts rule name              description
+>---- ---------------------- --------------------------------------------------
+>-1.0 ALL_TRUSTED            Passed through trusted hosts only via SMTP
+> 1.2 MISSING_HEADERS        Missing To: header
+> 1.0 MISSING_FROM           Missing From: header
+> 1.8 MISSING_SUBJECT        Missing Subject: header
+> 1.4 MISSING_DATE           Missing Date: header
+> 0.1 MISSING_MID            Missing Message-Id: header
+>
+*eof
 ****
-#
-#
-#
-exim -odi -bs -DOPT=";defer_ok;tmo=2s"
+exim -odi -oMt fromuser -bs -DOPT='<; 127.0.0.1 7833 ; HOSTIPV4 7834 pri=2 tmo=2s'
 ehlo test.ex
-mail from:<>
+mail from:<fromuser@myhost.test.ex>
 rcpt to:<userx@test.ex>
 data
-Date: Fri, 17 Dec 2004 14:35:01 +0100
-Subject: message should be accepted despite timeout
+Content-type: text/plain
 
+test
 .
 quit
 ****
 #
 #
-#
-server DIR/eximdir/fsec_sock
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<CONFIGURE
->ignored_response
-<SCAN
->LF>xxxINFECTED        blah    VNAME   blah
->LF>OK Scan ok.
-*eof
-****
-#
-#
-#
-exim -odi -bs -DOPT="; defer_ok ; tmo=5h"
-ehlo test.ex
-mail from:<>
-rcpt to:<userx@test.ex>
-data
-Date: Fri, 17 Dec 2004 14:35:01 +0100
-Subject: message should be rejected as the options are not relevant
-
-.
-quit
-****