1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00
Commit Graph

448 Commits

Author SHA1 Message Date
Dan Fandrich
f6d80d66a2 Added tests 633 through 637 to test the new file range support for SFTP.
All but the first test cause an infinite loop or other failure and so
are added to DISABLED.
2008-10-09 05:16:06 +00:00
Dan Fandrich
8dfddd279b Added tests 1082 through 1085 to test symbolic --interface parameters 2008-10-08 21:46:55 +00:00
Dan Fandrich
11a8a25528 Created test cases 1080 and 1081 to reproduce a problem of
CURLINFO_REDIRECT_URL leaking memory and returning incorrect results when
two URLs are requested. Reported by vmpdemo in bug #2152270
2008-10-08 03:32:10 +00:00
Dan Fandrich
b9ce871463 Changed the handling of read/write errors in Curl_perform() to allow a
a fresh connection to be made in such cases and the request retransmitted.
This should fix test case 160.  Added test case 1079 in an attempt to
test a similar connection dropping scenario, but as a race condition, it's
hard to test reliably.
2008-10-07 23:15:02 +00:00
Dan Fandrich
c3d871aef4 Added HTTP 1.0 downgrade tests with proxies 2008-09-06 18:24:04 +00:00
Daniel Stenberg
18110b519c - Martin Drasar provided the CURLOPT_POSTREDIR patch. It renames
CURLOPT_POST301 (but adds a define for backwards compatibility for you who
  don't define CURL_NO_OLDIES). This option allows you to now also change the
  libcurl behavior for a HTTP response 302 after a POST to not use GET in the
  subsequent request (when CURLOPT_FOLLOWLOCATION is enabled). I edited the
  patch somewhat before commit. The curl tool got a matching --post302
  option. Test case 1076 was added to verify this.
2008-09-05 16:13:20 +00:00
Dan Fandrich
85a79f9d67 Added tests 1071 through 1074 to test automatic downgrading from HTTP 1.1
to HTTP 1.0 upon receiving a response from the HTTP server.  Tests 1072
and 1073 are similar to test 1069 in that they involve the impossible
scenario of sending chunked data to a HTTP 1.0 server.  All these currently
fail and are added to DISABLED.

Added test 1075 to test --anyauth with Basic authentication.
2008-08-29 23:42:39 +00:00
Daniel Stenberg
d24465b79a test 1070 added 2008-08-29 10:48:27 +00:00
Dan Fandrich
93357ef017 Added test 1069 to test PUT from stdin without content length. It fails
in a similar manner to test 1065 so is added to DISABLED.
2008-08-28 02:18:44 +00:00
Dan Fandrich
753592cc70 Added test case 1068 to do a simple HTTP PUT from stdin 2008-08-28 02:03:54 +00:00
Daniel Stenberg
b34390017b added test case 1067 to verify --referer "firstone.html;auto" 2008-08-23 21:27:58 +00:00
Dan Fandrich
e3ad6d2bd1 Fixed a problem when --dump-header - was given with more than one URL,
which caused an error when the second header was dumped due to stdout
being closed.  Added test case 1066 to verify.  Also fixed a potential
problem where a closed file descriptor might be used for an upload
when more than one URL is given.
2008-08-22 22:57:25 +00:00
Yang Tse
2f71461b29 Added test case 557 to verify libcurl's internal curl_m*printf() functions
formatting functionality when handling signed and unsigned longs, as well as
our curl_off_t data type.
2008-08-18 09:58:08 +00:00
Dan Fandrich
a923d8541c Added test case 1065 to test a PUT with a single file but two URLs. This
was discovered to be problematic while investigating an incident reported by
Von back in May.  curl in this case doesn't include a Content-Length: or
Transfer-Encoding: chunked header which is illegal. This test case is
added to DISABLED until a solution is found.
2008-08-15 19:18:46 +00:00
Dan Fandrich
6e878d2ca4 Added test 1063 to test an invalid large range on a file: 2008-08-14 19:18:01 +00:00
Dan Fandrich
7eab7fa353 Fixed a buffer overflow problem in Curl_proxyCONNECT that could occur
when a server responded with long headers and data.  Luckily, the buffer
overflowed into another unused buffer, so no actual harm was done.
Added test cases 1060 and 1061 to verify.
2008-08-12 20:07:52 +00:00
Dan Fandrich
f1fe04245a Fixed a boundary condition error in ftp_readresp() whereby a non-terminal
line of a multiline FTP response whose last byte landed exactly at the end
of the BUFSIZE-length buffer would be treated as the terminal response
line.  The following response code read in would then actually be the
end of the previous response line, and all responses from then on would
correspond to the wrong command. Test case 1062 verifies this.

Stop closing a never-opened ftp socket.
2008-08-11 23:16:08 +00:00
Dan Fandrich
40b2e06a7f Added test1059 to test the FTP proxy tunnel problem fixed July 11. 2008-08-08 07:26:30 +00:00
Dan Fandrich
f27299dc3b Added tests 1057 and 1058 to test FTP and HTTPS transfers with ranges
relative to end of file.
2008-08-01 22:12:34 +00:00
Dan Fandrich
f3b4071209 Added test of IPv6 scope handling 2008-07-31 02:38:51 +00:00
Dan Fandrich
bc649593e4 Added test cases 1052 through 1055 to test uploading data from files
during redirects.  Test cases 1052 and 1055 show problems (maybe the same
root cause as 1051) and are disabled.
2008-07-30 21:04:44 +00:00
Dan Fandrich
1f26ea4a85 Added test case 1051 to test Location: following with PUT, as reported
by Ben Sutcliffe.  The test when run manually shows a problem in curl,
but the test harness web server doesn't run the test correctly so it's
disabled for now.
2008-07-30 07:24:59 +00:00
Dan Fandrich
adc032e7d8 Return an error code when extra files are found in filecheck: 2008-07-29 18:57:01 +00:00
Dan Fandrich
4ff37a4ed1 Added test case 1050 to test --ftp-port with an IPv6 address.
Made --interface tests less restrictive on host address.
2008-07-29 01:05:28 +00:00
Dan Fandrich
f042a7419d Added test cases 1045 through 1049 as simple tests of --interface using the
localhost interface.
2008-07-28 18:39:32 +00:00
Dan Fandrich
e06944438a Added test 1044 to test large file support in ftp with -I. 2008-07-26 20:09:36 +00:00
Dan Fandrich
aa4a7471dd Added test1042 and test1043 to test -C - on HTTP. 2008-07-15 04:12:15 +00:00
Dan Fandrich
69a03ce23c Added test1040 and test1041 to test -C - on HTTP. Test 1041 failed so it's
added to DISABLED.
2008-07-15 03:36:38 +00:00
Dan Fandrich
8d49a8f278 Added test cases 1038 and 1039 to test Adrian Kreher's report that ftp
uploads with -C - didn't resume properly, but the tests pass.
2008-07-11 05:08:06 +00:00
Dan Fandrich
bbb1b99ce1 Added tests 1036 and 1037 to verify resumed ftp downloads with -C - 2008-07-10 06:09:03 +00:00
Dan Fandrich
a25959184e Added test cases 1034 & 1035 to test IDN name conversion failures. 2008-07-07 23:52:52 +00:00
Daniel Stenberg
82412f218f Phil Blundell provided a fix for libcurl's treatment of unexpected 1xx
response codes. Previously libcurl would hang on such occurances. I added
test case 1033 to verify.
2008-07-03 08:47:53 +00:00
Daniel Stenberg
d92945bb8a - Eduard Bloch filed the debian bug report #487567
(http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=487567) pointing out that
  libcurl used Content-Range: instead of Range when doing a range request with
  --head (CURLOPT_NOBODY). This is now fixed and test case 1032 was added to
  verify.
2008-06-22 20:38:16 +00:00
Dan Fandrich
5304b13365 Added SSH failure test cases 628-632 2008-06-19 00:18:58 +00:00
Daniel Stenberg
f7815fa93c - Bug report #1973352 (http://curl.haxx.se/bug/view.cgi?id=1973352) identified
how the HTTP redirect following code didn't properly follow to a new URL if
  the new url was but a query string such as "Location: ?moo=foo". Test case
  1031 was added to verify this fix.
2008-05-26 20:39:41 +00:00
Daniel Stenberg
7f88e8badb Added test case 556 that uses curl_easy_send() and curl_easy_recv() 2008-05-13 21:42:07 +00:00
Daniel Stenberg
fc9e0d2249 - Ben Van Hof filed bug report #1945240: "libcurl sometimes sends body twice
when using CURL_AUTH_ANY" (http://curl.haxx.se/bug/view.cgi?id=1945240).
  The problem was that when libcurl rewound a stream meant for upload when it
  would prepare for a second request, it could accidentally continue the
  sending of the rewound data on the first request instead of on the second.
  Ben also provided test case 1030 that verifies this fix.
2008-05-03 21:45:12 +00:00
Daniel Stenberg
852989856d - To make it easier for applications that want lots of magic stuff done on
redirections and thus cannot use CURLOPT_FOLLOWLOCATION easily, we now
  introduce the new CURLINFO_REDIRECT_URL option that lets applications
  extract the URL libcurl would've redirected to if it had been told to. This
  then enables the application to continue to that URL as it thinks is
  suitable, without having to re-implement the magic of creating the new URL
  from the Location: header etc. Test 1029 verifies it.
2008-04-30 21:20:08 +00:00
Dan Fandrich
ab71654078 Added test 1028 to test an HTTP redirect to a FTP URL. 2008-04-29 02:30:09 +00:00
Dan Fandrich
7abf50a5c0 Added test cases 1026 and 1027 to do some rudimentary tests on the --manual
and --help options.
2008-04-18 22:31:52 +00:00
Daniel Stenberg
0331071346 Added test case 555, a variation of 547 but using multi interface instead of
easy. This was reported not working by Penugonda Chenna Reddy in
http://curl.haxx.se/mail/lib-2008-04/0046.html but I fail to repeat that
problem.
2008-04-16 21:11:46 +00:00
Dan Fandrich
a9591ad1b7 Added test case 1025 to test a command-line cookie with Location: following 2008-04-10 18:18:55 +00:00
Dan Fandrich
c97d112b30 Added test case 1024 to test a scenario similar to the one reported
by Ben Combee where libcurl would send the wrong cookie to a redirected
server.  libcurl was doing the right thing in this test case.
2008-04-10 04:21:08 +00:00
Daniel Stenberg
ac0b911eda oops, forgot to add test554 2008-04-04 11:39:32 +00:00
Dan Fandrich
10232bfe9e Added test627 to test SFTP with CURLOPT_NOBODY 2008-04-04 02:06:35 +00:00
Dan Fandrich
a57098ea9b Added test 626 to reproduce an infinite loop when given an invalid
SFTP quote command reported by Vincent Le Normand, but left it disabled.
2008-03-18 17:05:29 +00:00
Dan Fandrich
040a4443a1 Added tests 622-625 to test SFTP/SCP uploads. Test 625 was an attempt to
reproduce the --ftp-create-dirs problem reported by Brian Ulm, but that
seems to need a call curl_easy_reset() which this test case doesn't do.
2008-03-13 22:51:39 +00:00
Dan Fandrich
458925ae0b Added tests 618-621 to test SFTP/SCP transfers of more than one file
(test 620 tests the just-fixed problem reported by Brian Ulm).
2008-03-10 19:40:27 +00:00
Dan Fandrich
b16ea66cec Added tests 616 and 617 to see how SFTP and SCP cope with zero-length
files, as questioned by Mike Protts. SFTP does for me but SCP doesn't
so test 617 is disabled for now.
2008-03-06 01:15:28 +00:00
Daniel Stenberg
55700cb01f - We no longer support setting the CURLOPT_URL option from inside a callback
such as the CURLOPT_SSL_CTX_FUNCTION one treat that as if it was a Location:
  following. The patch that introduced this feature was done for 7.11.0, but
  this code and functionality has been broken since about 7.15.4 (March 2006)
  with the introduction of non-blocking OpenSSL "connects".

  It was a hack to begin with and since it doesn't work and hasn't worked
  correctly for a long time and nobody has even noticed, I consider it a very
  suitable subject for plain removal. And so it was done.
2008-02-20 08:28:02 +00:00
Dan Fandrich
0cae201044 Added test309 to test HTTP redirect to HTTPS URL 2008-02-19 21:57:41 +00:00
Dan Fandrich
ce1649564c Added tests 1022 and 1023 to validate output of curl-config --version and
--vernum
2008-02-08 01:21:03 +00:00
Daniel Stenberg
5f2055729e added test 1021 to verify my fix for bug report #1879375 2008-01-26 00:13:38 +00:00
Daniel Stenberg
c522f349fe Added test 553. This test case and code is based on the bug recipe Joe Malicki
provided for bug report #1871269, fixed on Jan 14 2008 before the 7.18.0
release.
2008-01-16 22:54:54 +00:00
Daniel Stenberg
08adf67969 Daniel Egger made CURLOPT_RANGE work on file:// URLs the very same way it
already worked for FTP:// URLs
2008-01-11 14:20:41 +00:00
Daniel Stenberg
f277124a0f In an attempt to repeat the problem in bug report #1850730
(http://curl.haxx.se/bug/view.cgi?id=1850730) I wrote up test case 552. The
test is doing a 70K POST with a read callback and an ioctl callback over a
proxy requiring Digest auth. The test case code is more or less identical to
the test recipe code provided by Spacen Jasset (who submitted the bug report).
2007-12-26 21:48:52 +00:00
Daniel Stenberg
c1730dc50a Add test 551 that tests callback-post over a proxy that requires Digest auth.
A failed attempt to repeat bug report #1850730 (ie the test works fine).
2007-12-15 22:13:07 +00:00
Daniel Stenberg
975812d246 add missing files 2007-12-08 22:56:05 +00:00
Daniel Stenberg
05221e9056 test1015 --data-urlencode 2007-11-26 11:04:21 +00:00
Dan Fandrich
6f33531861 Added test case 1014 to compare curl-config --features with curl --version 2007-11-01 03:09:27 +00:00
Dan Fandrich
16897354bc Added test case 1013 to check that curl-config --protocols matches the
protocols listed in curl --version
2007-11-01 00:36:55 +00:00
Dan Fandrich
38cd2d781f Added test case 546 to check that subsequent FTP transfers work after a
failed one using the multi interface
2007-10-29 22:57:31 +00:00
Dan Fandrich
1eac702c1a Added test case 2004.
Disable valgrind in test case 1004 due to a libtool bug.
2007-10-25 21:04:51 +00:00
Patrick Monnerat
0678a51d3b Allow test server to handle binary POSTs.
Tests 35, 544 545 added: binary data POSTs.
2007-10-25 19:40:05 +00:00
Dan Fandrich
65ed696625 Fixed the test TFTP server to support the >10000 test number notation
Added test cases 2002 and 2003 (the latter disabled for now)
2007-10-24 22:48:23 +00:00
Dan Fandrich
38649d1362 Added test cases 2000 and 2001 which test multiple protocols using the
same easy handle
Fixed the filecheck: make target to work outside the source tree
2007-10-24 19:40:07 +00:00
Daniel Stenberg
67d94514b0 Kim Rinnewitz reported that --local-port didn't work with TFTP transfers.
This happened because the tftp code always uncondionally did a bind()
without caring if one already had been done and then it failed. I wrote a
test case (1009) to verify this, but it is a bit error-prone since it will
have to pick a fixed local port number and since the tests are run on so
many different hosts in different situations I add it in disabled state.
2007-10-04 10:01:41 +00:00
Daniel Stenberg
119364741e known bug #46: chunked-encoded CONNECT responses from a http proxy now works.
Added test case 1008 to verify. Note that #47 is still there.
2007-10-02 10:21:36 +00:00
Daniel Stenberg
9ca2644429 Added test536 that was accidentally missing. I also wrote up a new makefile
target called 'filecheck' so that if you run 'make filecheck' in this directory
it'll check if the local files are also mentioned in the Makefile.am so that
they are properly included in release archives!
2007-09-30 22:58:24 +00:00
Daniel Stenberg
ec08e2f9f2 Alex Fishman reported a curl_easy_escape() problem that was made the
function do wrong on all input bytes that are >= 0x80 (decimal 128) due to a
signed / unsigned mistake in the code. I fixed it and added test case 543 to
verify.
2007-09-30 22:40:24 +00:00
Daniel Stenberg
fd4cf78f36 Philip Langdale provided the new CURLOPT_POST301 option for
curl_easy_setopt() that alters how libcurl functions when following
redirects. It makes libcurl obey the RFC2616 when a 301 response is received
after a non-GET request is made. Default libcurl behaviour is to change
method to GET in the subsequent request (like it does for response code 302
- because that's what many/most browsers do), but with this CURLOPT_POST301
option enabled it will do what the spec says and do the next request using
the same method again. I.e keep POST after 301.

The curl tool got this option as --post301

Test case 1011 and 1012 were added to verify.
2007-09-26 12:44:59 +00:00
Daniel Stenberg
775f86cb5a Immanuel Gregoire fixed KNOWN_BUGS #44: --ftp-method nocwd did not handle
URLs ending with a slash properly (it should list the contents of that
directory). Test case 351 brought back and also test 1010 was added.
2007-09-24 21:47:35 +00:00
Daniel Stenberg
9e88343a17 Daniel S (12 September 2007)
- Bug report #1792649 (http://curl.haxx.se/bug/view.cgi?id=1792649) pointed
  out a problem with doing an empty upload over FTP on a re-used connection.
  I added test case 541 to reproduce it and to verify the fix.

- I noticed while writing test 541 that the FTP code wrongly did a CWD on the
  second transfer as it didn't store and remember the "" path from the
  previous transfer so it would instead CWD to the entry path as stored. This
  worked, but did a superfluous command. Thus, test case 541 now also verifies
  this fix.
2007-09-11 22:23:57 +00:00
Dan Fandrich
d030dfa6e2 Added test case 1007 to test permission problem when uploading with TFTP
(to validate bug #1790403).
2007-09-07 20:05:20 +00:00
Dan Fandrich
f6251734fc Added more accurate error code returns from SFTP operations. Added test
case 615 to test an SFTP upload failure.
2007-08-30 23:03:59 +00:00
Daniel Stenberg
7cba40b218 Bug report #1779054 (http://curl.haxx.se/bug/view.cgi?id=1779054) pointed
out that libcurl didn't deal with large responses from server commands, when
the single response was consisting of multiple lines but of a total size of
16KB or more. Dan Fandrich improved the ftp test script and provided test
case 1006 to repeat the problem, and I fixed the code to make sure this new
test case runs fine.
2007-08-24 14:00:42 +00:00
Dan Fandrich
975fafdc49 Added test case 1005 to test excessively-long replies spread out over
multiple lines (similar to test case 1003).
2007-08-23 23:25:47 +00:00
Dan Fandrich
abca03cf36 Added test1004 to validate a previous fix for a memory leak when an
empty proxy server is selected.
2007-08-23 17:35:00 +00:00
Daniel Stenberg
381e372939 Bug report #1779054 (http://curl.haxx.se/bug/view.cgi?id=1779054) pointed
out that libcurl didn't deal with very long (>16K) FTP server response lines
properly. Starting now, libcurl will chop them off (thus the client app will
not get the full line) but survive and deal with them fine otherwise. Test
case 1003 was added to verify this.
2007-08-22 14:18:06 +00:00
Daniel Stenberg
3217809294 Robson Braga Araujo filed bug report #1776235
(http://curl.haxx.se/bug/view.cgi?id=1776235) about ftp requests with NOBODY
on a directory would do a "SIZE (null)" request. This is now fixed and test
case 1000 was added to verify.
2007-08-17 22:22:43 +00:00
Daniel Stenberg
54117be639 Moved the 5320 and 5322 into the 1000-series instead which is a documented
range. They are about FTP but the 100-199 range is full.
2007-08-17 22:11:25 +00:00
Daniel Stenberg
5a79532aee Song Ma provided a patch that cures a problem libcurl has when doing resume
HTTP PUT using Digest authentication. Test case 5320 and 5322 were also
added to verify the functionality.
2007-08-17 20:21:32 +00:00
Daniel Stenberg
6f750f3b57 Dmitriy Sergeyev reported a regression: resumed file:// transfers broke
after 7.16.2. This is much due to the different treatment file:// gets
internally, but now I added test 231 to make it less likely to happen again
without us noticing!
2007-08-02 14:09:08 +00:00
Daniel Stenberg
4bbcc47f3f Added test case 354 that makes a simple FTP retrieval without password, which
verifies the bug fix in #1757328.
2007-07-22 10:08:59 +00:00
Daniel Stenberg
15c8219340 Added test case 540 and lib540.c, the 'proxyauth.c' test app posted by Shmulik
Regev on the libcurl mailing list on 10 Jul 2007, converted to a test case.
2007-07-14 22:39:22 +00:00
Dan Fandrich
93bd512357 Fixed a curl memory leak reported by Song Ma with a modified version
of the patch he suggested.  Added his test case as test289 to verify.
2007-07-10 22:23:16 +00:00
Daniel Stenberg
fc3c5dae87 and fix another flaw in the singlecwd case when we get ftp://site.com/, also
from the #1739100 bug report
2007-06-19 12:33:28 +00:00
Daniel Stenberg
cc26cc5dcd Test listing of root dir with the three ftp-methods. KNOWN_BUGS #44 make me
disable test 351 by default by I add the test case anyway to make it easier
to work on this problem in the future.
2007-06-18 21:04:05 +00:00
Dan Fandrich
873d95a34c Incorporated Daniel Black's test706 and test707 SOCKS test cases. 2007-06-08 17:21:40 +00:00
Daniel Stenberg
e86dfd9688 added 703: a socks5 version of 702 2007-06-05 13:52:34 +00:00
Daniel Stenberg
a466b31574 Daniel Black's test suite fixes and initial test cases for SOCKS4/5 using
openssh
2007-06-05 13:50:59 +00:00
Dan Fandrich
ea43bb013b Added support for quote commands before a transfer using SFTP and test
case 614.
Allow SFTP quote commands chmod, chown, chgrp to set a value of 0.
2007-05-15 00:28:50 +00:00
Dan Fandrich
b0a4c992e7 Added SFTP directory listing test case 613. 2007-05-14 22:03:42 +00:00
Dan Fandrich
85707460e5 Added FTPS upload tests 408 and 409. 2007-05-10 20:03:20 +00:00
Dan Fandrich
ed998270aa Added FTPS test cases 406 and 407 2007-05-08 22:14:30 +00:00
Dan Fandrich
6a35841b2e Added tests 610-612 to test more SFTP post-quote commands. 2007-04-23 23:00:38 +00:00
Dan Fandrich
66fc5498d2 Added test cases 296, 297 and 298 to test --ftp-method handling 2007-04-18 06:30:28 +00:00
Dan Fandrich
71a0d50f48 Added test cases 294 and 295 to test --ftp-account handling 2007-04-13 20:59:15 +00:00
Dan Fandrich
27d2d78059 Added more SSH tests (left disabled for now). 2007-04-04 00:48:37 +00:00
Dan Fandrich
a209c32bf3 Resurrected old FTPS error tests 402 and 403 as 404 and 405. 2007-03-30 22:04:14 +00:00
Dan Fandrich
40981286ea Added HTTP --max-filesize tests and FTPS CCC failure test. 2007-03-30 18:50:55 +00:00
Dan Fandrich
ffb11ad5c6 Don't tear down the ftp connection if the maximum filesize was exceeded
and added tests 290 and 291 to check.
2007-03-30 01:13:47 +00:00
Dan Fandrich
fbb1e49215 Added FTP-SSL failure test 402 2007-03-30 00:08:41 +00:00
Dan Fandrich
c26320d94f Added ftps upload test 401 2007-03-29 22:50:23 +00:00
Dan Fandrich
2166645ce4 Added SFTP and SCP upload tests in test602 & test603 2007-03-26 19:23:00 +00:00
Dan Fandrich
0dd1219668 Fixed a memory leak when specifying a proxy with a file: URL and added
test case 288 to verify it.
2007-03-24 02:15:20 +00:00
Dan Fandrich
1bfa7dfe39 Added test infrastructure to support basic FTPS tests. This currently
supports only ftps:// URLs with --ftp-ssl-control specified, which
implicitly encrypts the control channel but not the data channels.  That
allows stunnel to be used with an unmodified ftp server in exactly the
same way that the test https server is set up.
Added test case 400 as a basic FTPS test.
2007-03-08 02:38:49 +00:00
Daniel Stenberg
abdbd3100f - Michael Wallner reported that when doing a CONNECT with a custom User-Agent
header, you got _two_ User-Agent headers in the CONNECT request...! Added
  test case 287 to verify the fix.
2007-01-29 09:26:36 +00:00
Dan Fandrich
32fe5b14ec Added simple OpenSSL crypto engine tests. 2007-01-16 18:34:58 +00:00
Dan Fandrich
f11d3c329c Added TFTP upload tests. 2007-01-15 21:06:12 +00:00
Dan Fandrich
5ec5b95f54 Added test for TFTP retrieve of boundary case 512 byte file. 2007-01-10 23:40:22 +00:00
Dan Fandrich
7efb955fd0 Added test of TFTP server error reporting. 2007-01-10 03:32:19 +00:00
Daniel Stenberg
88c8d72a21 Alexey Simak found out that when doing FTP with the multi interface and
something went wrong like it got a bad response code back from the server,
libcurl would leak memory. Added test case 538 to verify the fix.

I also noted that the connection would get cached in that case, which
doesn't make sense since it cannot be re-use when the authentication has
failed. I fixed that issue too at the same time, and also that the path
would be "remembered" in vain for cases where the connection was about to
get closed.
2006-12-11 09:32:58 +00:00
Daniel Stenberg
090f5a9a45 added the new test 282 2006-11-25 13:32:48 +00:00
Yang Tse
905ca77c9e test 518 is all about testing libcurl functionality
when more than FD_SETSIZE file descriptors are open.
This means that if for any reason we are not able to
open more than FD_SETSIZE file descriptors then test
518 should not be run.

test 537 is all about testing libcurl functionality
when the system has nearly exhausted the number of
free file descriptors. Test 537 will try to run with
very few free file descriptors.
2006-11-01 18:33:50 +00:00
Daniel Stenberg
cde5e35d9b Fixed CURLOPT_FAILONERROR to return CURLE_HTTP_RETURNED_ERROR even for the
case when 401 or 407 are returned, *IF* no auth credentials have been given.
The CURLOPT_FAILONERROR option is not possible to make fool-proof for 401
and 407 cases when auth credentials is given, but we've now covered this
somewhat more.

You might get some amounts of headers transferred before this situation is
detected, like for when a "100-continue" is received as a response to a
POST/PUT and a 401 or 407 is received immediately afterwards.

Added test 281 to verify this change.
2006-10-25 20:40:14 +00:00
Daniel Stenberg
a1de9367ec Bogdan Nicula's second test case (posted Sun, 08 Oct 2006) converted to test
case 535 and it now runs fine. Again a problem with the pipelining code not
taking all possible (error) conditions into account.
2006-10-09 06:58:05 +00:00
Daniel Stenberg
2ad7fcbc2f test 534 added in an attempt to repeat Bogdan Nicula's bug... 2006-10-08 10:51:53 +00:00
Daniel Stenberg
552b963e6d Dmitriy Sergeyev provided an example source code that crashed CVS libcurl
but that worked nicely in 7.15.5. I converted it into test case 532 and
fixed the problem.
2006-10-04 21:11:08 +00:00
Daniel Stenberg
5e0d9aea32 Support for FTP third party transfers is now dropped 2006-09-30 20:31:11 +00:00
Daniel Stenberg
ae13c93b7d Reported in #1561470 (http://curl.haxx.se/bug/view.cgi?id=1561470), libcurl
would crash if a bad function sequence was used when shutting down after
using the multi interface (i.e using easy_cleanup after multi_cleanup) so
precautions have been added to make sure it doesn't any more - test case 529
was added to verify.
2006-09-28 21:26:06 +00:00
Daniel Stenberg
b22aaeef6a added simple test of --ftp-alternative-to-user 2006-09-23 20:39:15 +00:00
Daniel Stenberg
e7d90e08b9 Added test case 531 in an attempt to repeat bug report #1561470
(http://curl.haxx.se/bug/view.cgi?id=1561470) that is said to crash when an
FTP upload fails with the multi interface. It did not, but I made a failed
upload still assume the control connection to be fine.
2006-09-21 20:52:20 +00:00
Daniel Stenberg
ec4a16f2e0 Armel Asselin fixed problems when you gave a proxy URL with user name and
empty password or no password at all. Test case 278 and 279 were added to
verify.
2006-09-20 21:49:41 +00:00
Daniel Stenberg
c866771cd2 Added a generic way to disable test cases when "all" is run, and added the
FTP 3rd party transfers to that file for now until I have them sorted out.
2006-09-13 10:16:36 +00:00
Daniel Stenberg
e3c15fc4b9 test 530 is the first ever HTTP pipelining test for libcurl 2006-09-08 11:56:56 +00:00
Daniel Stenberg
b7eeb6e67f Major overhaul introducing http pipelining support and shared connection
cache within the multi handle.
2006-09-07 21:49:20 +00:00
Daniel Stenberg
dc9f154823 added missing test 2006-08-31 22:18:08 +00:00
Daniel Stenberg
c10d15aa0f test case 277 - HTTP RFC1867-type formposting with custom Content-Type 2006-07-27 22:44:56 +00:00
Daniel Stenberg
bcc62cc9e3 #1451929 (http://curl.haxx.se/bug/view.cgi?id=1451929) detailed a bug that
occurred when asking libcurl to follow HTTP redirects and the original URL had
more than one question mark (?). Added test case 276 to verify.
2006-03-28 08:03:25 +00:00
Daniel Stenberg
ce09cedd2e added test524 2006-03-03 13:12:39 +00:00
Daniel Stenberg
80f2e3f263 test 275 makes a CONNECT through a proxy and then gets two pages from the
same server
2005-10-30 23:15:49 +00:00
Daniel Stenberg
966fa848a0 Nis Jorgensen filed bug report #1338648
(http://curl.haxx.se/bug/view.cgi?id=1338648) which really is more of a
feature request, but anyway. It pointed out that --max-redirs did not allow
it to be set to 0, which then would return an error code on the first
Location: found. Based on Nis' patch, now libcurl supports CURLOPT_MAXREDIRS
set to 0, or -1 for infinity. Added test case 274 to verify.
2005-10-27 22:05:38 +00:00
Daniel Stenberg
be9c873a6e Dave Dribin made libcurl understand and handle cases when the server
(wrongly) sends *two* WWW-Authenticate headers for Digest. While this should
never happen in a sane world, libcurl previously got into an infinite loop
when this occurred. Dave added test 273 to verify this.
2005-10-20 20:07:32 +00:00
Daniel Stenberg
68917eb517 added test case 272 for -z download over FTP when the timestamp is identical
to the remote one
2005-10-05 06:23:45 +00:00
Daniel Stenberg
da3992d2e9 added test 271 2005-09-19 22:04:14 +00:00
Daniel Stenberg
7e845e7cfd Added FTP_SKIP_PASV_IP and --ftp-skip-pasv-ip 2005-09-04 05:16:06 +00:00
Daniel Stenberg
a4773fcbbb Toby Peterson added CURLOPT_IGNORE_CONTENT_LENGTH to the library, accessible
from the command line tool with --ignore-content-length. This will make it
easier to download files from Apache 1.x (and similar) servers that are
still having problems serving files larger than 2 or 4 GB. When this option
is enabled, curl will simply have to wait for the server to close the
connection to signal end of transfer. I wrote test case 269 that runs a
simple test that this works.
2005-08-24 10:57:28 +00:00
Daniel Stenberg
9ad92b3007 added test 268 that makes curl -d @nonexisting 2005-08-12 22:09:21 +00:00
Daniel Stenberg
c0d343d56d do a POST with NTLM and add two custom headers 2005-08-11 21:33:40 +00:00
Daniel Stenberg
465e19dbe9 Adrian Schuur added trailer support in the chunked encoding stream. The
trailer is then sent to the normal header callback/stream.
2005-07-12 18:15:34 +00:00
Daniel Stenberg
20005a83d2 Andrew Bushnell provided enough info for me to tell that we badly needed to
fix the CONNECT authentication code with multi-pass auth methods (such as
NTLM) as it didn't previously properly ignore response-bodies - in fact it
stopped reading after all response headers had been received. This could
lead to libcurl sending the next request and reading the body from the first
request as response to the second request. (I also renamed the function,
which wasn't strictly necessary but...)

The best fix would to once and for all make the CONNECT code use the
ordinary request sending/receiving code, treating it as any ordinary request
instead of the special-purpose function we have now. It should make it
better for multi-interface too. And possibly lead to less code...

Added test case 265 for this. It doesn't work as a _really_ good test case
since the test proxy is too stupid, but the test case helps when running the
debugger to verify.
2005-07-03 22:25:15 +00:00
Daniel Stenberg
3b60bb7259 David Shaw's fix that unifies proxy string treatment so that a proxy given
with CURLOPT_PROXY can use a http:// prefix and user + password. The user
and password fields are now also URL decoded properly.

Test case 264 added to verify.
2005-06-22 22:24:10 +00:00
Daniel Stenberg
300b4a9158 Todd Kulesza reported a flaw in the proxy option, since a numerical IPv6
address was not possible to use. It is now, but requires it written
RFC2732-style, within brackets - which incidently is how you enter numerical
IPv6 addresses in URLs. Test case 263 added to verify.
2005-05-31 13:03:26 +00:00
Daniel Stenberg
a7846189cd Eric Cooper reported about a problem with HTTP servers that responds with
binary zeroes within the headers. They confused libcurl to do wrong so the
downloaded headers become incomplete. The fix is now verified with test case
262.
2005-05-29 22:30:48 +00:00
Daniel Stenberg
632cf13767 add test case 261, response code 226 to TYPE 2005-05-24 09:40:58 +00:00
Daniel Stenberg
4a091bbd8a Bug report #1204435 identified a problem with malformed URLs like
"http://somehost?data" as it added a slash too much in the request ("GET
/?data/"...). Added test case 260 to verify.
2005-05-18 20:01:01 +00:00
Daniel Stenberg
2b00ed7ef8 Added two test cases for multipart formpost over a proxy with --anyauth. Our
HTTP test server is a bit limited though, as it never responds to the POST
request until all data has been sent (and received)...
2005-05-06 23:22:33 +00:00
Daniel Stenberg
01165e08e0 Fred New reported a bug where we used Basic auth and user name and password in
.netrc, and when following a Location: the subsequent requests didn't properly
use the auth as found in the netrc file. Added test case 257 to verify my fix.
2005-04-25 21:39:48 +00:00
Daniel Stenberg
78a76dc905 test 256 is like test 38 but with proxy + proxy auth 2005-04-22 10:15:21 +00:00