From 5785ea1ab4fcb38be4e47da45b8b2d15421db42a Mon Sep 17 00:00:00 2001 From: mdecimus Date: Thu, 28 Dec 2023 09:44:12 +0100 Subject: [PATCH] SMTP smuggling tests --- src/request/receiver.rs | 61 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/src/request/receiver.rs b/src/request/receiver.rs index fb8e040..5d74034 100644 --- a/src/request/receiver.rs +++ b/src/request/receiver.rs @@ -261,6 +261,67 @@ mod tests { vec!["\r\na\rb\nc\r\n.d\r\n..\r\n", "\r\n.\r\n"], "\r\na\rb\nc\r\nd\r\n.\r\n", ), + // Test SMTP smuggling attempts + ( + vec![ + "\n.\r\n", + "MAIL FROM:\r\n", + "RCPT TO:\r\n", + "RCPT TO:\r\n", + "RCPT TO:\r\n", + "RCPT TO:\r\n", + "RCPT TO:\r\n", + "RCPT TO:\r\n", + "RCPT TO:\r\n", + "RCPT TO: