ftp: remove superfluous checking for crlf in user or pwd

... as this is already done much earlier in the URL parser.

Also add test case 894 that verifies that pop3 with an encodedd CR in
the user name is rejected.

Closes #4887
This commit is contained in:
Daniel Stenberg 2020-02-06 11:36:53 +01:00
parent c87730daeb
commit 950b53da0d
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2
3 changed files with 38 additions and 19 deletions

37
tests/data/test894 Normal file
View file

@ -0,0 +1,37 @@
<testcase>
<info>
<keywords>
POP3
Clear Text
RETR
</keywords>
</info>
#
# Server-side
<reply>
</reply>
#
# Client-side
<client>
<server>
pop3
</server>
<name>
POP3 with CR in username
</name>
<command>
pop3://user%0dFRIGGING_cmd:secret@%HOSTIP:%POP3PORT/894
</command>
</client>
#
# Verify data after the test has been "shot"
<verify>
# malformed URL
<errorcode>
3
</errorcode>
</verify>
</testcase>