Variables ${TESTDIR}/lib/vars.py
*** Variables ***
-${CONFIG} ${TESTDIR}/configs/plugins.conf
+${CONFIG} ${TESTDIR}/configs/plugins.conf
+${MESSAGE} ${TESTDIR}/messages/newlines.eml
${MESSAGE1} ${TESTDIR}/messages/fws_fn.eml
${MESSAGE2} ${TESTDIR}/messages/fws_fp.eml
${MESSAGE3} ${TESTDIR}/messages/fws_tp.eml
${MESSAGE4} ${TESTDIR}/messages/broken_richtext.eml
-${URL_TLD} ${TESTDIR}/../lua/unit/test_tld.dat
+${URL_TLD} ${TESTDIR}/../lua/unit/test_tld.dat
${RSPAMD_SCOPE} Test
${result} = Scan Message With Rspamc ${MESSAGE4}
Check Rspamc ${result} BROKEN_CONTENT_TYPE
+Dynamic Config
+ ${result} = Scan Message With Rspamc ${MESSAGE}
+ Check Rspamc ${result} SA_BODY_WORD (10
+ Check Rspamc ${result} \/ 20
+
*** Keywords ***
Rules Setup
${PLUGIN_CONFIG} = Get File ${TESTDIR}/configs/regexp.conf
--- /dev/null
+[
+ {
+ "metric": "default",
+ "actions": [
+ {
+ "name": "reject",
+ "value": 20.0
+ },
+ {
+ "name": "add header",
+ "value": 6.0
+ }
+ ],
+ "symbols": [
+ {
+ "name": "SA_BODY_WORD",
+ "value": 10.0
+ },
+ {
+ "name": "FORGED_RECIPIENTS",
+ "value": 0.0
+ },
+ {
+ "name": "PHISHING",
+ "value": 0.0
+ },
+ {
+ "name": "PRECEDENCE_BULK",
+ "value": 2.0
+ },
+ {
+ "name": "SPAM_FLAG",
+ "value": 6.0
+ },
+ {
+ "name": "BAYES_SPAM",
+ "value": 10.0
+ },
+ {
+ "name": "BAYES_HAM",
+ "value": -6.0
+ },
+ {
+ "name": "MISSING_TO",
+ "value": 3.0
+ },
+ {
+ "name": "FUZZY_DENIED",
+ "value": 0.0
+ },
+ {
+ "name": "DMARC_POLICY_QUARANTINE",
+ "value": 3.500000
+ },
+ {
+ "name": "DMARC_POLICY_SOFTFAIL",
+ "value": 2.0
+ },
+ {
+ "name": "DNSWL_BLOCKED",
+ "value": 1.0
+ },
+ {
+ "name": "RCVD_COUNT_TWO",
+ "value": 1.0
+ },
+ {
+ "name": "R_SPF_FAIL",
+ "value": 10.0
+ },
+ {
+ "name": "R_DKIM_ALLOW",
+ "value": -1.500000
+ },
+ {
+ "name": "FAKE_REPLY",
+ "value": 2.0
+ },
+ {
+ "name": "SUBJECT_ENDS_EXCLAIM",
+ "value": 2.0
+ },
+ {
+ "name": "FORGED_SENDER_MAILLIST",
+ "value": 1.0
+ },
+ {
+ "name": "RCVD_NO_TLS_LAST",
+ "value": 1.0
+ },
+ {
+ "name": "HFILTER_URL_ONLY",
+ "value": 4.200000
+ },
+ {
+ "name": "URI_COUNT_ODD",
+ "value": 2.0
+ },
+ {
+ "name": "FORGED_RECIPIENTS_MAILLIST",
+ "value": 1.0
+ },
+ {
+ "name": "SEM_URIBL_FRESH15",
+ "value": 4.0
+ },
+ {
+ "name": "FROM_NEQ_ENVFROM",
+ "value": 1.0
+ },
+ {
+ "name": "DMARC_POLICY_REJECT",
+ "value": 3.0
+ }
+ ]
+ }
+]
\ No newline at end of file