2007-11-26 06:04:21 -05:00
<testcase>
<info>
<keywords>
2012-11-19 11:54:52 -05:00
HTTP
HTTP POST
2007-11-26 06:04:21 -05:00
--data-urlencode
</keywords>
</info>
#
# Server-side
<reply>
<data>
HTTP/1.1 200 I am cool swsclose
Server: Cool server/10.0
Content-Length: 0
</data>
</reply>
#
# Client-side
<client>
<server>
http
</server>
<name>
--data-urlencode
</name>
<command>
2021-03-12 11:38:26 -05:00
http://%HOSTIP:%HTTPPORT/%TESTNUMBER --data-urlencode "my name is moo[]" --data-urlencode "y e s=s_i_r" --data-urlencode "v_alue@log/%TESTNUMBER.txt" --data-urlencode @log/%TESTNUMBER.txt
2007-11-26 06:04:21 -05:00
</command>
2021-03-12 11:38:26 -05:00
<file name="log/%TESTNUMBER.txt">
2007-11-26 06:04:21 -05:00
content to _?!#$'|<>
</file>
</client>
#
# Verify data after the test has been "shot"
<verify>
<protocol nonewline="yes">
2021-03-12 11:38:26 -05:00
POST /%TESTNUMBER HTTP/1.1
2007-11-26 06:04:21 -05:00
Host: %HOSTIP:%HTTPPORT
2020-10-02 07:45:24 -04:00
User-Agent: curl/%VERSION
2007-11-26 06:04:21 -05:00
Accept: */*
2021-04-15 00:45:21 -04:00
Content-Length: 119
2007-11-26 06:04:21 -05:00
Content-Type: application/x-www-form-urlencoded
2021-04-15 00:45:21 -04:00
my+name+is+moo%5B%5D&y e s=s_i_r&v_alue=content+to+_%3F%21%23%24%27%7C%3C%3E%0A&content+to+_%3F%21%23%24%27%7C%3C%3E%0A
2007-11-26 06:04:21 -05:00
</protocol>
</verify>
</testcase>