tests: Corrected the SMTP tests to be RFC2821 compliant
authorSteve Holme <steve_holme@hotmail.com>
Sun, 28 Apr 2013 15:12:40 +0000 (16:12 +0100)
committerSteve Holme <steve_holme@hotmail.com>
Sun, 28 Apr 2013 15:14:58 +0000 (16:14 +0100)
The emails that are sent to the server during these tests were
incorrectly formatted as they contained one or more LF terminated lines
rather than being CRLF terminated as per Section 2.3.7 of RFC-2821.

This wasn't a problem for the test suite as the <stdin> data matched the
<upload> data but anyone using these tests as reference would be sending
incorrect data to a server.

tests/data/test900
tests/data/test901
tests/data/test902
tests/data/test903
tests/data/test904
tests/data/test905
tests/data/test906
tests/data/test907
tests/data/test908

index 2b6681b9eebbe4a6e7a163b5e312ead410e40e66..e71fa94fdb9fa96d19a206041c08f776cfb7b6ed 100644 (file)
@@ -20,10 +20,10 @@ smtp
 SMTP
  </name>
 <stdin>
-From: different
-To: another
-
-body
+From: different\r
+To: another\r
+\r
+body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 900@foo --mail-rcpt 900@foobar.example --mail-from 900@from -T -
@@ -42,10 +42,10 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-From: different
-To: another
-
-body
+From: different\r
+To: another\r
+\r
+body\r
 \r
 .\r
 </upload>
index 5617c6d737c8dd9043939ff031aec3de2246c518..cc3409990846dc7c51368992fd34301bcc5c5d54 100644 (file)
@@ -20,16 +20,16 @@ smtp
 SMTP with CRLF-dot-CRLF in data
  </name>
 <stdin>
-From: different
-To: another
-
+From: different\r
+To: another\r
+\r
 \r
 .\r
 .\r
 \r
 .\r
-
-body
+\r
+body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 901@foo --mail-from '<901@from>' -T -
@@ -47,16 +47,16 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-From: different
-To: another
-
+From: different\r
+To: another\r
+\r
 \r
 ..\r
 ..\r
 \r
 ..\r
-
-body
+\r
+body\r
 \r
 .\r
 </upload>
index 5cb920c789cd03cf80e46987efc43d557f2f8383..c3b9fb44235c8e9c8296b522b5294c1cc39dd936 100644 (file)
@@ -26,10 +26,10 @@ smtp
 RFC821-only SMTP server (EHLO not supported)
  </name>
 <stdin>
-From: different
-To: another
-
-body
+From: different\r
+To: another\r
+\r
+body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 902@foo --mail-from 902@from -T -
@@ -48,10 +48,10 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-From: different
-To: another
-
-body
+From: different\r
+To: another\r
+\r
+body\r
 \r
 .\r
 </upload>
index 35bac4567a160cd346b1b206e765950e70d22be1..defadf903616d6420d9e2915c5aa05ad4931ed22 100644 (file)
@@ -28,7 +28,7 @@ smtp
 SMTP plain authentication
  </name>
 <stdin>
-mail body
+mail body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 903@foo --mail-from 903@from -u test:1234 -T -
@@ -48,7 +48,7 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-mail body
+mail body\r
 \r
 .\r
 </upload>
index 9c32a25e0afc7d27c11a4b5ffeff6843faf21704..19e6f222623c995ac4492e992f26b0ecf83d772a 100644 (file)
@@ -28,7 +28,7 @@ smtp
 SMTP login authentication
  </name>
 <stdin>
-mail body
+mail body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 904@foo --mail-from 904@from -u test:1234 -T -
@@ -49,7 +49,7 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-mail body
+mail body\r
 \r
 .\r
 </upload>
index d583619037b332cec15d84ae126308998f779b11..451a73d49eb67edb62896bddec685ba8d046274e 100644 (file)
@@ -31,7 +31,7 @@ crypto
 SMTP CRAM-MD5 authentication
  </name>
 <stdin>
-mail body
+mail body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 905@foo --mail-from 905@from -u tim:tanstaaftanstaaf -T -
@@ -51,7 +51,7 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-mail body
+mail body\r
 \r
 .\r
 </upload>
index da196009e0d6be902ef54c115c789e1bf4169b8e..80c1e7ee617470845ec796278ea3cd6a4d29b5d5 100644 (file)
@@ -20,10 +20,10 @@ smtp
 SMTP without --mail-from
  </name>
 <stdin>
-From: different
-To: another
-
-body
+From: different\r
+To: another\r
+\r
+body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 906@foo -T -
@@ -41,10 +41,10 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-From: different
-To: another
-
-body
+From: different\r
+To: another\r
+\r
+body\r
 \r
 .\r
 </upload>
index f86bc8dca9bd9ac9d6e67d99cf64b5f9e412c1b8..45e453db0b2be4c740c86ee548bd16b761077416 100644 (file)
@@ -27,7 +27,7 @@ smtp
 SMTP plain authentication with initial response
  </name>
 <stdin>
-mail body
+mail body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 907@foo --mail-from 907@from -u test:1234 --sasl-ir -T -
@@ -46,7 +46,7 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-mail body
+mail body\r
 \r
 .\r
 </upload>
index ec14d3934fc6c7e5e3094c7714f22aef432efafd..c1689287f8b2aeb72ffa1cdf6c59b62012c4f6a7 100644 (file)
@@ -27,7 +27,7 @@ smtp
 SMTP login authentication with initial response
  </name>
 <stdin>
-mail body
+mail body\r
 </stdin>
  <command>
 smtp://%HOSTIP:%SMTPPORT/user --mail-rcpt 908@foo --mail-from 908@from -u test:1234 --sasl-ir -T -
@@ -47,7 +47,7 @@ DATA
 QUIT\r
 </protocol>
 <upload>
-mail body
+mail body\r
 \r
 .\r
 </upload>