smtp: allow suffix behind a mail address for RFC 3461

Verified in test 3215

Closes #16643
This commit is contained in:
Dominik Tomecki 2025-07-30 09:48:13 +02:00 committed by Daniel Stenberg
parent 3ccffad28d
commit 450c00f983
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
6 changed files with 98 additions and 19 deletions

View file

@ -278,8 +278,7 @@ test3032 test3033 \
test3100 test3101 test3102 test3103 test3104 test3105 \
\
test3200 test3201 test3202 test3203 test3204 test3205 test3207 test3208 \
test3209 test3210 test3211 test3212 test3213 test3214 \
\
test3209 test3210 test3211 test3212 test3213 test3214 test3215 \
test4000 test4001
EXTRA_DIST = $(TESTCASES) DISABLED

56
tests/data/test3215 Normal file
View file

@ -0,0 +1,56 @@
<testcase>
<info>
<keywords>
SMTP DSN
</keywords>
</info>
#
# Server-side
<reply>
# Special Replies, so the server does not have to understand DSN
<servercmd>
REPLY MAIL 250 Ok
REPLY RCPT 250 Ok
</servercmd>
</reply>
#
# Client-side
<client>
<server>
smtp
</server>
<name>
SMTP DSN
</name>
<stdin>
From: different
To: another
body
</stdin>
<command>
smtp://%HOSTIP:%SMTPPORT/%TESTNUMBER --mail-rcpt "<recipient@example.com> NOTIFY=SUCCESS,FAILURE" --mail-from "<sender@example.com> RET=HDRS" -T -
</command>
</client>
#
# Verify data after the test has been "shot"
<verify>
<protocol>
EHLO %TESTNUMBER
MAIL FROM:<sender@example.com> RET=HDRS
RCPT TO:<recipient@example.com> NOTIFY=SUCCESS,FAILURE
DATA
QUIT
</protocol>
<upload>
From: different
To: another
body
.
</upload>
</verify>
</testcase>