Daniel Stenberg [Wed, 6 Nov 2013 22:57:44 +0000 (23:57 +0100)]
parseconfig: dash options can't specified with colon or equals
Bug: http://curl.haxx.se/bug/view.cgi?id=1297
Reported-by: Michael Osipov
Daniel Stenberg [Fri, 29 Nov 2013 14:10:27 +0000 (15:10 +0100)]
curl.1: -G also takes --data-urlencode data
Daniel Stenberg [Thu, 28 Nov 2013 22:31:31 +0000 (23:31 +0100)]
globbing: curl glob counter mismatch with {} list use
The "fixed string" function wrongly bumped the "urlnum" counter which
made curl output the total number of URLs wrong when using
{one,two,three} lists in globs.
Reported-by: Michael-O
Bug: http://curl.haxx.se/bug/view.cgi?id=1305
Christian Grothoff [Wed, 27 Nov 2013 22:37:09 +0000 (23:37 +0100)]
sessioninfo.c: Added sample code for CURLINFO_TLS_SESSION
Added a simple example to show how one can use CURLINFO_TLS_SESSION for
obtaining extensive TLS certificate information.
Steve Holme [Wed, 27 Nov 2013 22:44:09 +0000 (22:44 +0000)]
multi.c: Fixed compilation error introduced in commit
a900d45489fc14
Systems that define SIGPIPE_VARIABLE as a noop would not compile as
restore_pipe was defined afterwards.
Christian Grothoff [Wed, 27 Nov 2013 22:28:26 +0000 (23:28 +0100)]
curl_easy_getopt: Handle API violation gracefully
This fixes a NULL dereference in the case where the client asks for
CURLINFO_TLS_SESSION data after the (TLS) session has already been
destroyed (i.e. curl_easy_perform has already completed for this
handle). Instead of crashing, we now return a CURLSSLBACKEND_NONE
error.
Steve Holme [Wed, 27 Nov 2013 22:33:22 +0000 (22:33 +0000)]
KNOWN_BUGS: #86: Disconnect commands may not be sent by IMAP, POP3 and SMTP
Jeff King [Mon, 25 Nov 2013 14:43:21 +0000 (15:43 +0100)]
curl_multi_cleanup: ignore SIGPIPE
This is an extension to the fix in
7d80ed64e43515. We may
call Curl_disconnect() while cleaning up the multi handle,
which could lead to openssl sending packets, which could get
a SIGPIPE.
Signed-off-by: Jeff King <peff@peff.net>
Jeff King [Mon, 25 Nov 2013 14:35:37 +0000 (15:35 +0100)]
sigpipe: factor out sigpipe_reset from easy.c
Commit
7d80ed64e43515 introduced some helpers to handle
sigpipe in easy.c. However, that fix was incomplete, and we
need to add more callers in other files. The first step is
making the helpers globally accessible.
Since the functions are small and should generally end up
inlined anyway, we simply define them in the header as
static functions.
Signed-off-by: Jeff King <peff@peff.net>
Björn Stenberg [Mon, 25 Nov 2013 23:04:28 +0000 (00:04 +0100)]
connect: Try next ip directly after immediate connect fail
This fixes a rare Happy Eyeballs bug where if the first IP family runs
out of addresses before the second-family-timer fires, and the second
IP family's first connect fails immediately, no further IPs of the
second family are attempted.
Daniel Stenberg [Sun, 24 Nov 2013 22:42:54 +0000 (23:42 +0100)]
hostip: don't prune DNS cache entries that are in use
When adding entries to the DNS cache with CURLOPT_RESOLVE, they are
marked 'inuse' forever to prevent them from ever being removed in normal
operations. Still, the code that pruned out-of-date DNS entries didn't
care for the 'inuse' struct field and pruned it anyway!
Reported-by: Romulo A. Ceccon
Bug: http://curl.haxx.se/bug/view.cgi?id=1303
Steve Holme [Sun, 24 Nov 2013 18:00:18 +0000 (18:00 +0000)]
RELEASE-NOTES: Synced with
35e476a3f6cdd5
Steve Holme [Sun, 24 Nov 2013 17:55:15 +0000 (17:55 +0000)]
tests: Re-ordered test arguments to match other IMAP tests
Steve Holme [Sun, 24 Nov 2013 16:19:12 +0000 (16:19 +0000)]
tests: Corrected login "username" authentication responses
Steve Holme [Sun, 24 Nov 2013 12:33:21 +0000 (12:33 +0000)]
tests: Added error code explanation comments
Steve Holme [Sun, 24 Nov 2013 10:59:59 +0000 (10:59 +0000)]
tests: Removed expected QUIT response from graceful cancellation tests
A failure during authentication, which is performed as part of the
CONNECT phrase (for IMAP, POP3 and SMTP) is considered by the multi-
interface as being closed prematurely (aka a dead connection). As such
these protocols cannot issue the relevant QUIT or LOGOUT command.
Temporarily fixed the test cases until we can fix this properly.
Steve Holme [Sat, 23 Nov 2013 15:06:31 +0000 (15:06 +0000)]
tests: Added SMTP graceful authentication cancellation tests
Steve Holme [Sat, 23 Nov 2013 14:46:32 +0000 (14:46 +0000)]
tests: Added POP3 graceful authentication cancellation tests
Steve Holme [Sat, 23 Nov 2013 22:14:34 +0000 (22:14 +0000)]
ftpserver.pl: Reworked fix from commit
7a36b2abc06862
Steve Holme [Sat, 23 Nov 2013 19:19:12 +0000 (19:19 +0000)]
ftpserver.pl: Fixed unknown IMAP command "*"
Steve Holme [Sat, 23 Nov 2013 16:25:37 +0000 (16:25 +0000)]
ftpserver.pl: Fixed servercmd REPLY with * detection
Steve Holme [Sat, 23 Nov 2013 14:26:33 +0000 (14:26 +0000)]
tests: Added IMAP graceful authentication cancellation tests
Steve Holme [Sat, 23 Nov 2013 14:06:10 +0000 (14:06 +0000)]
tests: Moved CR LF in URL tests to their respective protocol groups
Steve Holme [Sat, 23 Nov 2013 09:35:35 +0000 (09:35 +0000)]
smtp: Post SMTP command expansion tidy up
Removed unnecessary SMTP_STOP state changes on failure.
Removed hard return on failure in smtp_state_data_resp().
Steve Holme [Fri, 22 Nov 2013 12:59:35 +0000 (12:59 +0000)]
symbols-in-versions: Added missing CURLSSLBACKEND_* symbols
Steve Holme [Fri, 22 Nov 2013 07:30:00 +0000 (07:30 +0000)]
symbols-in-versions: Fixed missing CURLINFO_TLS_SESSION
Christian Grothoff [Sun, 17 Nov 2013 19:49:16 +0000 (20:49 +0100)]
curl_easy_getinfo: Added CURLINFO_TLS_SESSION for accessing TLS internals
Added new API for returning a SSL backend type and pointer, in order to
allow access to the TLS internals, that may then be used to obtain X509
certificate information for example.
Steve Holme [Sun, 17 Nov 2013 16:55:56 +0000 (16:55 +0000)]
RELEASE-NOTES: Synced with
8191800a0c8ff7
Steve Holme [Sun, 17 Nov 2013 16:39:02 +0000 (16:39 +0000)]
smtp: Fixed space being sent in non --mail-rcpt based requests
Commands such as NOOP, RSET and HELP would be sent with a space at the
end of the command, for example: "NOOP ".
Steve Holme [Sun, 17 Nov 2013 10:13:05 +0000 (10:13 +0000)]
tests: Added SMTP NOOP and RSET tests
Steve Holme [Sun, 17 Nov 2013 12:37:59 +0000 (12:37 +0000)]
test928: Corrected typo in expected data from commit
df58084695ce9b
Steve Holme [Sun, 17 Nov 2013 10:03:25 +0000 (10:03 +0000)]
tests: Added SMTP HELP test
Steve Holme [Sun, 17 Nov 2013 09:45:08 +0000 (09:45 +0000)]
smtp: Changed the default command to HELP when no options are specified
Otherwise a NOOP operation would be performed which a) only returns a
single line response and not a multiline response where -I needs to be
used, and b) provides an inconsistent user experience compared to that
of the POP3 and IMAP protocols.
Steve Holme [Sun, 17 Nov 2013 09:00:21 +0000 (09:00 +0000)]
smtp:Fixed memory leak from commit
dac01ff6d788b2
The buffer allocated by smtp_parse_custom_request() was not freed.
Steve Holme [Sat, 16 Nov 2013 22:56:11 +0000 (22:56 +0000)]
connect: Close open but unconnected socket in singleipconnect()
singleipconnect() could return the file descriptor of an open socket
even though the function returned a CURLE_COULDNT_CONNECT error code
from commit
ed1662c374361a and
02fbc26d59c591.
This could cause tests 19, 704 and 1233 to fail on FreeBSD, AIX and
Solaris.
Steve Holme [Sat, 16 Nov 2013 12:10:15 +0000 (12:10 +0000)]
tests: Added SMTP EXPN command test
Steve Holme [Sat, 16 Nov 2013 20:33:08 +0000 (20:33 +0000)]
test926: Corrected unknown user reply from commit
0d735c29f92748
The error code should not be sent as data as it isn't passed onto the
client as body data, so cannot be compared in the test suite against
expected data.
Steve Holme [Sat, 16 Nov 2013 17:19:26 +0000 (17:19 +0000)]
tests: Corrected missing data reply sections from
3d50e91aeef8cc
Steve Holme [Sat, 16 Nov 2013 12:00:30 +0000 (12:00 +0000)]
tests: Added SMTP VRFY command tests
Steve Holme [Sat, 16 Nov 2013 11:11:45 +0000 (11:11 +0000)]
ftpserver.pl: Added support for new SMTP commands
Steve Holme [Fri, 15 Nov 2013 22:20:56 +0000 (22:20 +0000)]
smtp: Fixed broken RCPT TO from commit
0ea4a80bb23666
Daniel Stenberg [Fri, 15 Nov 2013 21:43:34 +0000 (22:43 +0100)]
smtp_state_mail_resp: removed unused variable 'smtp'
Steve Holme [Fri, 15 Nov 2013 21:15:38 +0000 (21:15 +0000)]
DOCS: Updated curl_easy_setopt.3 following recent SMTP changes
* Added information about the verify and expand commands to
CURLOPT_MAIL_RCPT.
* Reworked CURLOPT_CUSTOMREQUEST section, adding information about IMAP
and SMTP custom commands.
Steve Holme [Fri, 15 Nov 2013 20:55:55 +0000 (20:55 +0000)]
DOCS: Updated manpage following recent SMTP modifications
* Added SMTP section to --request
* Expanded --mail-rcpt to describe the usage when using the verify and
expand commands.
Steve Holme [Fri, 15 Nov 2013 18:30:04 +0000 (18:30 +0000)]
smtp: Simplified the next RCPT TO logic
Steve Holme [Fri, 15 Nov 2013 20:35:43 +0000 (20:35 +0000)]
lib1507.c: Added missing set of CURLOPT_UPLOAD option
Although this option should have already been set, the SMTP module can
now download information from and send instructional commands to, an
SMTP server, requiring the option to be set in order to perform a mail
transfer.
Steve Holme [Fri, 15 Nov 2013 20:22:01 +0000 (20:22 +0000)]
smtp.c: Fixed trailing whitespace
Steve Holme [Fri, 15 Nov 2013 18:20:12 +0000 (18:20 +0000)]
smtp: Added support for VRFY and EXPN commands
Steve Holme [Fri, 15 Nov 2013 16:10:05 +0000 (16:10 +0000)]
smtp: Added support for NOOP and RSET commands
Steve Holme [Fri, 15 Nov 2013 12:50:37 +0000 (12:50 +0000)]
smtp: Fixed handling of multiline server greeting responses
Incorrectly processed multiline server greeting responses as "wanted"
continue responses in smtp_endofresp(), from commit
f16c0de4e9bbe3,
which in turn broke the SMTP server detection in the test suite,
because the EHLO command would not be sent.
Steve Holme [Fri, 15 Nov 2013 12:14:09 +0000 (12:14 +0000)]
smtp.c: Fixed compilation error from commit
f16c0de4e9bbe3
warning: unused variable 'smtpc'
Steve Holme [Fri, 15 Nov 2013 10:54:47 +0000 (10:54 +0000)]
smtp: Fixed processing of more than one response when sent in same packet
Added a loop to smtp_statemach_act() in which Curl_pp_readresp() is
called until the cache is drained. Without this multiple responses
received in a single packet could result in a hang or delay.
Steve Holme [Fri, 15 Nov 2013 10:46:29 +0000 (10:46 +0000)]
smtp: Moved EHLO response handling to smtp_state_ehlo_resp()
Similar to the processing of untagged CAPABILITY responses in IMAP moved
the processing of multiline EHLO responses to smtp_state_ehlo_resp() and
introduced an internal response code of one to differentiate a multiline
continuation from the end of command. This also allows for the separate
processing of multiline responses from commands such as VRFY and EXPN.
Steve Holme [Thu, 14 Nov 2013 20:43:15 +0000 (20:43 +0000)]
connect: Forgot to correct line endings before push in commit
ed1662c374361a
Björn Stenberg [Tue, 12 Nov 2013 20:09:03 +0000 (21:09 +0100)]
connect: Return the socket descriptor even on fail
singleipconnect() did not return the open socket descriptor on some
errors, thereby sometimes causing a socket leak. This patch ensures
the socket is always returned.
Daniel Stenberg [Thu, 14 Nov 2013 02:58:25 +0000 (18:58 -0800)]
configure: Fix test with -Werror=implicit-function-declaration
The ipv6 auto-detect test in configure returns a false negative when
CFLAGS contains -Werror=implicit-function-declaration. (I have been
using this flag to detect code issues that would result in SEGVs on
x86_64-cygwin.)
Patch-by: Yaakov Selkowitz
Bug: http://curl.haxx.se/bug/view.cgi?id=1304
Steve Holme [Wed, 13 Nov 2013 17:31:42 +0000 (17:31 +0000)]
test825: Corrected typo from commit
b29217d0d682d4
Steve Holme [Wed, 13 Nov 2013 10:12:01 +0000 (10:12 +0000)]
RELEASE-NOTES: Synced with
bde901ad89a6f1
Steve Holme [Wed, 13 Nov 2013 09:17:15 +0000 (09:17 +0000)]
test922: Corrected title to match other OAuth 2.0 tests
Steve Holme [Wed, 13 Nov 2013 09:12:15 +0000 (09:12 +0000)]
tests: Added IMAP OAuth 2.0 authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 09:02:20 +0000 (09:02 +0000)]
tests: Added IMAP NTLM authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 08:52:25 +0000 (08:52 +0000)]
tests: Added IMAP login authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 08:42:30 +0000 (08:42 +0000)]
tests: Added IMAP plain authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 08:35:13 +0000 (08:35 +0000)]
test873: Use proper padding in NTLM responses
Nick Zitzmann [Wed, 13 Nov 2013 02:26:20 +0000 (20:26 -0600)]
darwinssl: check for SSLSetSessionOption() presence when toggling BEAST
Even though this is only a formality (since not many people build on
Mavericks while targeting Leopard), since we still support Leopard
at the earliest, we might as well be pedantic.
Nick Zitzmann [Wed, 13 Nov 2013 02:18:04 +0000 (20:18 -0600)]
darwinssl: PKCS#12 import feature now requires Lion or later
It turns out that some of the constants necessary to make this feature
work are missing from Snow Leopard's Security framework even though
they are defined in the headers.
Bug: http://curl.haxx.se/mail/lib-2013-11/0076.html
Reported by: myriachan
Steve Holme [Wed, 13 Nov 2013 00:33:00 +0000 (00:33 +0000)]
tests: Added POP3 OAuth 2.0 authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 00:23:03 +0000 (00:23 +0000)]
tests: Added POP3 NTLM authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 00:13:06 +0000 (00:13 +0000)]
tests: Added POP3 login authentication with initial response test
Steve Holme [Wed, 13 Nov 2013 00:03:09 +0000 (00:03 +0000)]
tests: Added POP3 plain authentication with initial response test
Steve Holme [Tue, 12 Nov 2013 20:29:58 +0000 (20:29 +0000)]
TODO: Added auth= in URLs to the wish list for HTTP
Steve Holme [Tue, 12 Nov 2013 19:01:04 +0000 (19:01 +0000)]
curl_easy_setopt: Added the ability to set the login options separately
Rather than set the authentication options as part of the login details
specified in the URL, or via the older CURLOPT_USERPWD option, added a
new libcurl option to allow the login options to be set separately.
Daniel Stenberg [Tue, 12 Nov 2013 17:28:07 +0000 (09:28 -0800)]
curl.1: mention that -O does no URL decoding
Tomas Hoger [Mon, 11 Nov 2013 15:20:14 +0000 (16:20 +0100)]
curl_easy_setopt.3: clarify CURLOPT_SSL_VERIFYHOST documentation
- better describe what happens when 1 is specified as parameter
- clarify what "is ignored" means for NSS builds
Steve Holme [Tue, 12 Nov 2013 12:34:56 +0000 (12:34 +0000)]
runtests.pl: Added SSPI detection
Steve Holme [Tue, 12 Nov 2013 09:59:22 +0000 (09:59 +0000)]
multi: Small code tidy up to avoid hard return
Steve Holme [Tue, 12 Nov 2013 09:42:59 +0000 (09:42 +0000)]
tests: Updated CRAM-MD5 tests to use test user details
Björn Stenberg [Mon, 11 Nov 2013 22:43:48 +0000 (23:43 +0100)]
multi: Set read socket when returning READSOCK(0)
This patch fixes and issue introduced in commit
7d7df831981fee, if the
tunnel state was TUNNEL_CONNECT, waitconnect_getsock() would return a
bitmask indicating a readable socket but never stored the socket in the
return array.
Daniel Stenberg [Mon, 11 Nov 2013 07:46:27 +0000 (08:46 +0100)]
bump: next release will be 7.34.0
Due to all the news and changes.
Björn Stenberg [Thu, 7 Nov 2013 23:09:20 +0000 (00:09 +0100)]
connect: Close temporary sockets in conn_free()
The temporary sockets used for Happy Eyeballs were not closed properly,
if curl exited prematurely, which this patch fixes.
Steve Holme [Sun, 10 Nov 2013 20:22:44 +0000 (20:22 +0000)]
tests: Corrected titles of POP3 and SMTP OAuth 2.0 tests
Steve Holme [Sun, 10 Nov 2013 20:20:20 +0000 (20:20 +0000)]
test823: Fixed expected authentication text from commit
e10a26a9d6d6de
Fixed authentication text due to incorrect digest-uri property.
Steve Holme [Sun, 10 Nov 2013 20:15:00 +0000 (20:15 +0000)]
test821: Fixed expected authentication text from commit
2d5455feac9984
Steve Holme [Sun, 10 Nov 2013 18:16:21 +0000 (18:16 +0000)]
RELEASE-NOTES: Synced with
0f81fbe5da6643
Kim Vandry [Sun, 10 Nov 2013 17:08:57 +0000 (12:08 -0500)]
ares: Fixed compilation under Visual Studio 2012
Steve Holme [Sun, 10 Nov 2013 17:00:00 +0000 (17:00 +0000)]
tests: Added IMAP OAuth 2.0 authentication test
Steve Holme [Sun, 10 Nov 2013 16:51:45 +0000 (16:51 +0000)]
tests: Added IMAP DIGEST-MD5 authentication test
Steve Holme [Sun, 10 Nov 2013 16:42:30 +0000 (16:42 +0000)]
tests: Added IMAP NTLM authentication test
Steve Holme [Sun, 10 Nov 2013 16:33:25 +0000 (16:33 +0000)]
tests: Added IMAP CRAM-MD5 authentication test
Steve Holme [Sun, 10 Nov 2013 16:08:12 +0000 (16:08 +0000)]
test819: Fixed expected authentication text from commit
76f924131c9fd3
Steve Holme [Thu, 7 Nov 2013 20:12:51 +0000 (20:12 +0000)]
ftpserver.pl: Reworked custom reply handling code
1) To fix issues with IMAP custom replies
2) So initial space is not required in IMAP display text
3) To be more readable and understandable
Steve Holme [Sun, 10 Nov 2013 10:20:50 +0000 (10:20 +0000)]
ftpserver.pl: Reworked unrecognised command responses
As the IMAP regex could fail and $1 would not contain the command id
updated the unrecognised command response to be more generic and
realistic (like those used in the command handlers).
Additionally updated the POP3, SMTP and FTP responses.
Steve Holme [Sun, 10 Nov 2013 10:08:32 +0000 (10:08 +0000)]
ftpserver.pl: Fixed processing of IMAP authentication strings
Daniel Stenberg [Fri, 8 Nov 2013 23:07:32 +0000 (00:07 +0100)]
cmake: fix Windows build with IPv6 support
Patch-by: "Z98"
Steve Holme [Wed, 6 Nov 2013 12:31:46 +0000 (12:31 +0000)]
Revert "ftpserver.pl: Corrected logic from commit
27b7b1062f9d97"
This reverts commit
558034ab7002d1 as it appears to break the auto
builds. More thought is required for this!
Steve Holme [Wed, 6 Nov 2013 08:07:59 +0000 (08:07 +0000)]
ftpserver.pl: Corrected logic from commit
27b7b1062f9d97
Steve Holme [Wed, 6 Nov 2013 07:19:01 +0000 (07:19 +0000)]
ftpserver.pl: Fixed IMAP cmdid being sent on custom responses
Steve Holme [Wed, 6 Nov 2013 00:09:15 +0000 (00:09 +0000)]
tests: Added IMAP login authentication test
Steve Holme [Wed, 6 Nov 2013 00:00:00 +0000 (00:00 +0000)]
tests: Added IMAP plain authentication test
Steve Holme [Tue, 5 Nov 2013 23:30:12 +0000 (23:30 +0000)]
url.c: Very small amount of policing