Skip to content

Commit

Permalink
[Test] Bad Boundary
Browse files Browse the repository at this point in the history
  • Loading branch information
korgoth1 committed Sep 27, 2019
1 parent 8e5517a commit f47059d
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/functional/cases/280_rules.robot
Expand Up @@ -12,6 +12,7 @@ ${MESSAGE1} ${TESTDIR}/messages/fws_fn.eml
${MESSAGE2} ${TESTDIR}/messages/fws_fp.eml
${MESSAGE3} ${TESTDIR}/messages/fws_tp.eml
${MESSAGE4} ${TESTDIR}/messages/broken_richtext.eml
${MESSAGE5} ${TESTDIR}/messages/badboundary.eml
${URL_TLD} ${TESTDIR}/../lua/unit/test_tld.dat
${RSPAMD_SCOPE} Test

Expand Down Expand Up @@ -40,6 +41,10 @@ Dynamic Config
Check Rspamc ${result} SA_BODY_WORD (10
Check Rspamc ${result} \/ 20

Broken boundary
${result} = Scan Message With Rspamc ${MESSAGE4}
Check Rspamc ${result} BROKEN_CONTENT_TYPE

*** Keywords ***
Rules Setup
${PLUGIN_CONFIG} = Get File ${TESTDIR}/configs/regexp.conf
Expand Down
17 changes: 17 additions & 0 deletions test/functional/messages/badboundary.eml
@@ -0,0 +1,17 @@
Content-Type: multipart/mixed; boundary="===============3209040583106423479=="
MIME-Version: 1.0
From: test@example.org
To: test@example.org
Date: Thu, 26 Sep 2019 15:52:32 -0000
Subject: Test message
Message-ID: <156951315267.43830.14912869070271436609@example.org>

--===============3209040583106423479==
Content-Type: image/gif
MIME-Version: 1.0
Content-Transfer-Encoding: base64
Content-Disposition: attachment; filename="Transparent.gif"
R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7
--===============3209040583106423479==

0 comments on commit f47059d

Please sign in to comment.