commit 4e9c57b: [Test] Add tests for sign maps
Vsevolod Stakhov
vsevolod at highsecure.ru
Tue Apr 9 11:49:04 UTC 2019
Author: Vsevolod Stakhov
Date: 2019-04-09 12:43:51 +0100
URL: https://github.com/rspamd/rspamd/commit/4e9c57b2182b43e60ac8454b0eaadf5b5612e4be
[Test] Add tests for sign maps
---
.../131_dkim_signing/{003_eddsa.robot => 007_sign_maps.robot} | 11 +++--------
test/functional/configs/dkim_signing/sign_maps.conf | 9 +++++++++
2 files changed, 12 insertions(+), 8 deletions(-)
diff --git a/test/functional/cases/131_dkim_signing/003_eddsa.robot b/test/functional/cases/131_dkim_signing/007_sign_maps.robot
similarity index 79%
copy from test/functional/cases/131_dkim_signing/003_eddsa.robot
copy to test/functional/cases/131_dkim_signing/007_sign_maps.robot
index ea2fe03be..69d4c9a92 100644
--- a/test/functional/cases/131_dkim_signing/003_eddsa.robot
+++ b/test/functional/cases/131_dkim_signing/007_sign_maps.robot
@@ -19,19 +19,14 @@ TEST SIGNED
Check Rspamc ${result} DKIM-Signature:
Should Contain ${result.stdout} DKIM_SIGNED
-TEST NOT SIGNED - USERNAME WRONG DOMAIN
- ${result} = Scan Message With Rspamc ${MESSAGE} -u bob at example.tk
- Check Rspamc ${result} DKIM-Signature: inverse=1
- Should Not Contain ${result.stdout} DKIM_SIGNED
-
-TEST NOT SIGNED - USERNAME WRONG PUBKEY
- ${result} = Scan Message With Rspamc ${MESSAGE_FAIL} -u bob at invalid.za.org
+TEST NOT SIGNED - FROM WRONG DOMAIN
+ ${result} = Scan Message With Rspamc ${MESSAGE_FAIL} -u bob at cacophony.za.org
Check Rspamc ${result} DKIM-Signature: inverse=1
Should Not Contain ${result.stdout} DKIM_SIGNED
*** Keywords ***
DKIM Signing Setup
- ${PLUGIN_CONFIG} = Get File ${TESTDIR}/configs/dkim_signing/eddsa.conf
+ ${PLUGIN_CONFIG} = Get File ${TESTDIR}/configs/dkim_signing/sign_maps.conf
Set Suite Variable ${PLUGIN_CONFIG}
Generic Setup PLUGIN_CONFIG
diff --git a/test/functional/configs/dkim_signing/sign_maps.conf b/test/functional/configs/dkim_signing/sign_maps.conf
new file mode 100644
index 000000000..9e63b7fc4
--- /dev/null
+++ b/test/functional/configs/dkim_signing/sign_maps.conf
@@ -0,0 +1,9 @@
+dkim_signing {
+ signing_table = [
+ "*@cacophony.za.org cacophony.za.org",
+ ];
+
+ key_table = [
+ "cacophony.za.org %:eddsa:m5kGxtckRfsNe5EuYTe7bvkDjSh7LXaX3aXyIMPGLR0=",
+ ];
+}
\ No newline at end of file
More information about the Commits
mailing list