diff options
author | korgoth1 <vladislav.stakhov@gmail.com> | 2019-08-30 21:07:25 +0300 |
---|---|---|
committer | korgoth1 <vladislav.stakhov@gmail.com> | 2019-08-30 21:07:25 +0300 |
commit | 03677971af95908e7b6a7f961d310acd6688a70d (patch) | |
tree | 4fc82d8f3f96fd3d7ad09ed8351313f99b418f0a /test/functional | |
parent | 3ee33462d0c730ef2f1446d21e90d34ab90de081 (diff) | |
download | rspamd-03677971af95908e7b6a7f961d310acd6688a70d.tar.gz rspamd-03677971af95908e7b6a7f961d310acd6688a70d.zip |
[Test] uribl in mail address
Diffstat (limited to 'test/functional')
-rw-r--r-- | test/functional/cases/340_surbl.robot | 9 | ||||
-rw-r--r-- | test/functional/configs/plugins.conf | 5 | ||||
-rw-r--r-- | test/functional/configs/surbl.conf | 10 | ||||
-rw-r--r-- | test/functional/messages/mailadr.eml | 4 |
4 files changed, 27 insertions, 1 deletions
diff --git a/test/functional/cases/340_surbl.robot b/test/functional/cases/340_surbl.robot index a533afdf5..58be332f8 100644 --- a/test/functional/cases/340_surbl.robot +++ b/test/functional/cases/340_surbl.robot @@ -60,6 +60,15 @@ SURBL Example.com domain image false Should Not Contain ${result.stdout} DBL_PHISH ( Should Not Contain ${result.stdout} URIBL_BLACK ( +SURBL @example.com mail + ${result} = Scan Message With Rspamc ${TESTDIR}/messages/mailadr.eml + Should Contain ${result.stdout} URIBL_IN_MAIL ( + Should Not Contain ${result.stdout} RSPAMD_URIBL + Should Not Contain ${result.stdout} DBL_SPAM ( + Should Not Contain ${result.stdout} RSPAMD_URIBL ( + Should Not Contain ${result.stdout} DBL_PHISH ( + Should Not Contain ${result.stdout} URIBL_BLACK ( + *** Keywords *** Surbl Setup ${PLUGIN_CONFIG} = Get File ${TESTDIR}/configs/surbl.conf diff --git a/test/functional/configs/plugins.conf b/test/functional/configs/plugins.conf index d3394ef17..ac68ec5cb 100644 --- a/test/functional/configs/plugins.conf +++ b/test/functional/configs/plugins.conf @@ -545,6 +545,11 @@ options = { replies = ["127.0.1.2"]; }, { + name = "user.example.com.test2.uribl"; + type = a; + replies = ["127.0.1.5"]; + }, + { name = "example.net.test2.uribl"; type = a; replies = ["127.0.1.4"]; diff --git a/test/functional/configs/surbl.conf b/test/functional/configs/surbl.conf index 967c170ae..6acf73275 100644 --- a/test/functional/configs/surbl.conf +++ b/test/functional/configs/surbl.conf @@ -1,4 +1,3 @@ - surbl { rules { "RSPAMD_URIBL" { @@ -64,5 +63,14 @@ EOD; end EOD; } + "URIBL_IN_MAIL" { + suffix = "test2.uribl"; + no_ip = true; + check_emails = true; + + ips = { + URIBL_IN_MAIL = "127.0.1.5"; + } + } } }
\ No newline at end of file diff --git a/test/functional/messages/mailadr.eml b/test/functional/messages/mailadr.eml new file mode 100644 index 000000000..bad36c511 --- /dev/null +++ b/test/functional/messages/mailadr.eml @@ -0,0 +1,4 @@ +Content-Type: text/html + +helo +<a href="mailto:user@example.com">Send email</a>
\ No newline at end of file |