commit 6c74a69: [TEST] PHISH Senders
korgoth1
vladislav.stakhov at gmail.com
Thu Aug 13 19:35:07 UTC 2020
Author: korgoth1
Date: 2020-08-06 17:01:26 +0300
URL: https://github.com/rspamd/rspamd/commit/6c74a6910ab0e9d02175a313828d89447cd11a40
[TEST] PHISH Senders
---
test/functional/cases/280_rules.robot | 21 +++++++++++++++++++++
.../messages/{btc3.eml => phish_sender.eml} | 3 ++-
.../messages/{btc3.eml => phish_sender2.eml} | 4 +++-
.../messages/{btc3.eml => phish_sender3.eml} | 3 ++-
.../messages/{btc3.eml => phish_sender4.eml} | 4 +++-
.../messages/{btc3.eml => phish_sender5.eml} | 3 ++-
6 files changed, 33 insertions(+), 5 deletions(-)
diff --git a/test/functional/cases/280_rules.robot b/test/functional/cases/280_rules.robot
index 18e3f3850..b62ed89bc 100644
--- a/test/functional/cases/280_rules.robot
+++ b/test/functional/cases/280_rules.robot
@@ -84,6 +84,27 @@ FROM_NEQ_ENVFROM
${result} = Scan Message With Rspamc ${MESSAGE8} --from test at test.net
Check Rspamc ${result} FROM_NEQ_ENVFROM
+PHISH_SENDER_A
+ ${result} = Scan Message With Rspamc ${TESTDIR}/messages/phish_sender.eml
+ Should Contain ${result.stdout} MULTIPLE_FROM (9.00)[any at attack.com,admin at legitimate.com]
+ Should Contain ${result.stdout} MULTIPLE_UNIQUE_HEADERS (7.00)[From]
+
+PHISH_SENDER_B
+ ${result} = Scan Message With Rspamc ${TESTDIR}/messages/phish_sender2.eml
+ Should Contain ${result.stdout} SOMETHING
+
+PHISH_SENDER_C
+ ${result} = Scan Message With Rspamc ${TESTDIR}/messages/phish_sender3.eml
+ Should Contain ${result.stdout} SOMETHING
+
+PHISH_SENDER_D
+ ${result} = Scan Message With Rspamc ${TESTDIR}/messages/phish_sender4.eml
+ Should Contain ${result.stdout} SOMETHING
+
+PHISH_SENDER_E
+ ${result} = Scan Message With Rspamc ${TESTDIR}/messages/phish_sender5.eml
+ Should Contain ${result.stdout} SOMETHING
+
*** Keywords ***
Rules Setup
diff --git a/test/functional/messages/btc3.eml b/test/functional/messages/phish_sender.eml
similarity index 93%
copy from test/functional/messages/btc3.eml
copy to test/functional/messages/phish_sender.eml
index d55c9d6ae..813c8d005 100644
--- a/test/functional/messages/btc3.eml
+++ b/test/functional/messages/phish_sender.eml
@@ -1,6 +1,7 @@
Received: by mail-lf1-f54.gulugulu.com with SMTP id j14so14439709lfg.9
for <test at test.ru>; Mon, 27 Apr 2020 09:54:21 -0700 (PDT)
-From: test at test.com
+From: <any at attack.com>
+From: <admin at legitimate.com>
Date: Mon, 27 Apr 2020 19:54:10 +0300
Message-ID: <CA+1S=h4aGimA6vSBJF=t1F+5z-Mua5+Cimf+NU_NDWJk8ZNOcw at mail.gmail.com>
Subject: Fwd:
diff --git a/test/functional/messages/btc3.eml b/test/functional/messages/phish_sender2.eml
similarity index 93%
copy from test/functional/messages/btc3.eml
copy to test/functional/messages/phish_sender2.eml
index d55c9d6ae..fa37bd02f 100644
--- a/test/functional/messages/btc3.eml
+++ b/test/functional/messages/phish_sender2.eml
@@ -1,6 +1,8 @@
Received: by mail-lf1-f54.gulugulu.com with SMTP id j14so14439709lfg.9
for <test at test.ru>; Mon, 27 Apr 2020 09:54:21 -0700 (PDT)
-From: test at test.com
+From
+: <any at attack.com>
+From: <admin at legitimate.com>
Date: Mon, 27 Apr 2020 19:54:10 +0300
Message-ID: <CA+1S=h4aGimA6vSBJF=t1F+5z-Mua5+Cimf+NU_NDWJk8ZNOcw at mail.gmail.com>
Subject: Fwd:
diff --git a/test/functional/messages/btc3.eml b/test/functional/messages/phish_sender3.eml
similarity index 93%
copy from test/functional/messages/btc3.eml
copy to test/functional/messages/phish_sender3.eml
index d55c9d6ae..90313b94d 100644
--- a/test/functional/messages/btc3.eml
+++ b/test/functional/messages/phish_sender3.eml
@@ -1,6 +1,7 @@
Received: by mail-lf1-f54.gulugulu.com with SMTP id j14so14439709lfg.9
for <test at test.ru>; Mon, 27 Apr 2020 09:54:21 -0700 (PDT)
-From: test at test.com
+From: <any at attack.com>
+From : <admin at legitimate.com>
Date: Mon, 27 Apr 2020 19:54:10 +0300
Message-ID: <CA+1S=h4aGimA6vSBJF=t1F+5z-Mua5+Cimf+NU_NDWJk8ZNOcw at mail.gmail.com>
Subject: Fwd:
diff --git a/test/functional/messages/btc3.eml b/test/functional/messages/phish_sender4.eml
similarity index 92%
copy from test/functional/messages/btc3.eml
copy to test/functional/messages/phish_sender4.eml
index d55c9d6ae..9798a0692 100644
--- a/test/functional/messages/btc3.eml
+++ b/test/functional/messages/phish_sender4.eml
@@ -1,6 +1,8 @@
Received: by mail-lf1-f54.gulugulu.com with SMTP id j14so14439709lfg.9
for <test at test.ru>; Mon, 27 Apr 2020 09:54:21 -0700 (PDT)
-From: test at test.com
+From
+: <any at attack.com>
+Sender: <admin at legitimate.com>
Date: Mon, 27 Apr 2020 19:54:10 +0300
Message-ID: <CA+1S=h4aGimA6vSBJF=t1F+5z-Mua5+Cimf+NU_NDWJk8ZNOcw at mail.gmail.com>
Subject: Fwd:
diff --git a/test/functional/messages/btc3.eml b/test/functional/messages/phish_sender5.eml
similarity index 90%
copy from test/functional/messages/btc3.eml
copy to test/functional/messages/phish_sender5.eml
index d55c9d6ae..c8cff6c15 100644
--- a/test/functional/messages/btc3.eml
+++ b/test/functional/messages/phish_sender5.eml
@@ -1,6 +1,7 @@
Received: by mail-lf1-f54.gulugulu.com with SMTP id j14so14439709lfg.9
for <test at test.ru>; Mon, 27 Apr 2020 09:54:21 -0700 (PDT)
-From: test at test.com
+From: <any at attack.com>, <any2 at attack.com>
+Sender: <admin at legitimate.com>
Date: Mon, 27 Apr 2020 19:54:10 +0300
Message-ID: <CA+1S=h4aGimA6vSBJF=t1F+5z-Mua5+Cimf+NU_NDWJk8ZNOcw at mail.gmail.com>
Subject: Fwd:
More information about the Commits
mailing list