Commit Graph

312 Commits

Author SHA1 Message Date
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