mirror of
https://github.com/curl/curl.git
synced 2026-08-25 07:03:31 +03:00
curl_get_line: make sure lines end with newline
Verify with test 792 and 793 Reported-by: z2_ Closes #17697
This commit is contained in:
parent
e29f11f2d6
commit
52f58ebb10
5 changed files with 123 additions and 11 deletions
|
|
@ -110,7 +110,7 @@ test736 test737 test738 test739 test740 test741 test742 test743 test744 \
|
|||
test745 test746 test747 test748 test749 test750 test751 test752 test753 \
|
||||
test754 \
|
||||
test780 test781 test782 test783 test784 test785 test786 test787 test788 \
|
||||
test789 test790 test791 \
|
||||
test789 test790 test791 test792 test793 \
|
||||
\
|
||||
test799 test800 test801 test802 test803 test804 test805 test806 test807 \
|
||||
test808 test809 test810 test811 test812 test813 test814 test815 test816 \
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
<keywords>
|
||||
HTTP
|
||||
--netrc-file
|
||||
netrc
|
||||
</keywords>
|
||||
</info>
|
||||
|
||||
|
|
|
|||
48
tests/data/test792
Normal file
48
tests/data/test792
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
<testcase>
|
||||
<info>
|
||||
<keywords>
|
||||
netrc
|
||||
FTP
|
||||
</keywords>
|
||||
</info>
|
||||
#
|
||||
# Server-side
|
||||
<reply>
|
||||
<data>
|
||||
content
|
||||
</data>
|
||||
</reply>
|
||||
|
||||
#
|
||||
# Client-side
|
||||
<client>
|
||||
<server>
|
||||
ftp
|
||||
</server>
|
||||
<features>
|
||||
proxy
|
||||
</features>
|
||||
<name>
|
||||
.netrc with embedded NULL byte
|
||||
</name>
|
||||
<command>
|
||||
--netrc --netrc-file %LOGDIR/netrc%TESTNUMBER ftp://%HOSTIP:%FTPPORT/%TESTNUMBER
|
||||
</command>
|
||||
<file name="%LOGDIR/netrc%TESTNUMBER" >
|
||||
machine %HOSTIP login username password%hex[%00]hex% hello
|
||||
</file>
|
||||
</client>
|
||||
|
||||
<verify>
|
||||
<protocol crlf="yes">
|
||||
USER username
|
||||
PASS
|
||||
PWD
|
||||
EPSV
|
||||
TYPE I
|
||||
SIZE %TESTNUMBER
|
||||
RETR %TESTNUMBER
|
||||
QUIT
|
||||
</protocol>
|
||||
</verify>
|
||||
</testcase>
|
||||
48
tests/data/test793
Normal file
48
tests/data/test793
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
<testcase>
|
||||
<info>
|
||||
<keywords>
|
||||
netrc
|
||||
FTP
|
||||
</keywords>
|
||||
</info>
|
||||
#
|
||||
# Server-side
|
||||
<reply>
|
||||
<data>
|
||||
content
|
||||
</data>
|
||||
</reply>
|
||||
|
||||
#
|
||||
# Client-side
|
||||
<client>
|
||||
<server>
|
||||
ftp
|
||||
</server>
|
||||
<features>
|
||||
proxy
|
||||
</features>
|
||||
<name>
|
||||
.netrc with embedded NULL byte, with quoted token
|
||||
</name>
|
||||
<command>
|
||||
--netrc --netrc-file %LOGDIR/netrc%TESTNUMBER ftp://%HOSTIP:%FTPPORT/%TESTNUMBER
|
||||
</command>
|
||||
<file name="%LOGDIR/netrc%TESTNUMBER" >
|
||||
machine %HOSTIP login username "password"%hex[%00]hex% hello
|
||||
</file>
|
||||
</client>
|
||||
|
||||
<verify>
|
||||
<protocol crlf="yes">
|
||||
USER username
|
||||
PASS
|
||||
PWD
|
||||
EPSV
|
||||
TYPE I
|
||||
SIZE %TESTNUMBER
|
||||
RETR %TESTNUMBER
|
||||
QUIT
|
||||
</protocol>
|
||||
</verify>
|
||||
</testcase>
|
||||
Loading…
Add table
Add a link
Reference in a new issue