Compare commits
38 Commits
HTTPS-prox
...
curl-7_46_
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e2ae32ff5f | ||
|
|
6623a485d3 | ||
|
|
940c2f51aa | ||
|
|
a47137c4a5 | ||
|
|
5648f0a32c | ||
|
|
2fddc4e3e1 | ||
|
|
e55f15454e | ||
|
|
fe7c39d353 | ||
|
|
8f281fb76d | ||
|
|
8cbd80686e | ||
|
|
a14fa8f8ff | ||
|
|
81ae6d01fa | ||
|
|
19a8afb3c0 | ||
|
|
78c25c854a | ||
|
|
db05d7a731 | ||
|
|
cd2b73b3ed | ||
|
|
5b96b5e79e | ||
|
|
99d17a5e2b | ||
|
|
facf2925c7 | ||
|
|
be0d4141af | ||
|
|
40c349ada9 | ||
|
|
bb9ec5ebb2 | ||
|
|
c341311a0e | ||
|
|
fc5d783589 | ||
|
|
98acebb526 | ||
|
|
06b288a72d | ||
|
|
d55f9071fb | ||
|
|
b7f3f1b68f | ||
|
|
c2f1730e17 | ||
|
|
8d17117683 | ||
|
|
c90e348579 | ||
|
|
f024ece8c7 | ||
|
|
ad6f6e17d3 | ||
|
|
0ddc59be0a | ||
|
|
bbb34b6f15 | ||
|
|
41efdadf09 | ||
|
|
6af80afe49 | ||
|
|
80562083da |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -49,3 +49,4 @@ missing
|
|||||||
mkinstalldirs
|
mkinstalldirs
|
||||||
tags
|
tags
|
||||||
test-driver
|
test-driver
|
||||||
|
scripts/_curl
|
||||||
|
|||||||
@@ -140,7 +140,7 @@ CLEANFILES = $(VC6_LIBDSP) $(VC6_SRCDSP) $(VC7_LIBVCPROJ) $(VC7_SRCVCPROJ) \
|
|||||||
|
|
||||||
bin_SCRIPTS = curl-config
|
bin_SCRIPTS = curl-config
|
||||||
|
|
||||||
SUBDIRS = lib src include
|
SUBDIRS = lib src include scripts
|
||||||
DIST_SUBDIRS = $(SUBDIRS) tests packages docs
|
DIST_SUBDIRS = $(SUBDIRS) tests packages docs
|
||||||
|
|
||||||
pkgconfigdir = $(libdir)/pkgconfig
|
pkgconfigdir = $(libdir)/pkgconfig
|
||||||
@@ -160,10 +160,10 @@ dist-hook:
|
|||||||
done)
|
done)
|
||||||
|
|
||||||
html:
|
html:
|
||||||
cd docs; make html
|
cd docs && make html
|
||||||
|
|
||||||
pdf:
|
pdf:
|
||||||
cd docs; make pdf
|
cd docs && make pdf
|
||||||
|
|
||||||
check: test examples check-docs
|
check: test examples check-docs
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ Curl and libcurl 7.46.0
|
|||||||
Command line options: 177
|
Command line options: 177
|
||||||
curl_easy_setopt() options: 221
|
curl_easy_setopt() options: 221
|
||||||
Public functions in libcurl: 61
|
Public functions in libcurl: 61
|
||||||
Contributors: 1322
|
Contributors: 1340
|
||||||
|
|
||||||
This release includes the following changes:
|
This release includes the following changes:
|
||||||
|
|
||||||
@@ -68,6 +68,25 @@ This release includes the following bugfixes:
|
|||||||
o typecheck-gcc.h: add some missing options
|
o typecheck-gcc.h: add some missing options
|
||||||
o curl: mark two more options strings for --libcurl output
|
o curl: mark two more options strings for --libcurl output
|
||||||
o openssl: Free modules on cleanup [20]
|
o openssl: Free modules on cleanup [20]
|
||||||
|
o CURLMOPT_PUSHFUNCTION.3: *_byname() returns only the first header
|
||||||
|
o getconnectinfo: Don't call recv(2) if socket == -1
|
||||||
|
o http2: http_done: don't free already-freed push headers
|
||||||
|
o zsh completion: Preserve single quotes in output [21]
|
||||||
|
o os400: Provide options for libssh2 use in compile scripts.
|
||||||
|
o build: Fix theoretical infinite loops [22]
|
||||||
|
o pop3: Differentiate between success and continuation responses
|
||||||
|
o examples: Fixed compilation warnings
|
||||||
|
o schannel: Use GetVersionEx() when VerifyVersionInfo() isn't available
|
||||||
|
o CURLOPT_HEADERFUNCTION.3: fix typo
|
||||||
|
o curl: expanded the -XHEAD warning text
|
||||||
|
o done: make sure the final progress update is made [23]
|
||||||
|
o build: Install zsh completion [24]
|
||||||
|
o RTSP: do not add if-modified-since without timecondition [25]
|
||||||
|
o curl: Fixed display of URL index in password prompt for --next
|
||||||
|
o nonblock: fix setting non-blocking mode for Amiga [26]
|
||||||
|
o http2 push: add missing inits of new stream [27]
|
||||||
|
o http2: convert some verbose output into debug-only output
|
||||||
|
o Curl_read_plain: clean up ifdefs that break statements [28]
|
||||||
|
|
||||||
This release includes the following known bugs:
|
This release includes the following known bugs:
|
||||||
|
|
||||||
@@ -76,13 +95,15 @@ This release includes the following known bugs:
|
|||||||
This release would not have looked like this without help, code, reports and
|
This release would not have looked like this without help, code, reports and
|
||||||
advice from friends like these:
|
advice from friends like these:
|
||||||
|
|
||||||
Anders Bakken, Dan Fandrich, Daniel Hwang, Daniel Stenberg, Dmitry S. Baikov,
|
Anders Bakken, Dan Fandrich, Daniel Hwang, Daniel Shahaf, Daniel Stenberg,
|
||||||
Douglas Creager, Erik Johansson, Gisle Vanem, Javier G. Sogo, John Levon,
|
Davey Shafik, Dmitry S. Baikov, Douglas Creager, Erik Johansson,
|
||||||
Jonas Minnberg, Justin Ehlert, Kamil Dudka, Kang Lin, Kurt Fankhauser,
|
Flavio Medeiros, Gisle Vanem, Javier G. Sogo, John Levon, Jonas Minnberg,
|
||||||
Lauri Kasanen, Marcel Raad, Patrick Monnerat, Rainer Jung, Ray Satiro,
|
Justin Ehlert, Kamil Dudka, Kang Lin, Kurt Fankhauser, Lauri Kasanen,
|
||||||
Richard Hosking, Sebastian Pohlschmidt, Stefan Bühler, Steve Holme,
|
Lukas Ruzicka, Marcel Raad, Michał Piechowski, Mohammad AlSaleh, Norbert Kett,
|
||||||
Svyatoslav Mishyn, Tatsuhiro Tsujikawa, Tim Rühsen, xiangbin li,
|
Patrick Monnerat, Rainer Jung, Ray Satiro, Richard Hosking,
|
||||||
(28 contributors)
|
Sebastian Pohlschmidt, Stefan Bühler, Steve Holme, Svyatoslav Mishyn,
|
||||||
|
Tatsuhiro Tsujikawa, Tim Rühsen, Xiangbin Li,
|
||||||
|
(35 contributors)
|
||||||
|
|
||||||
Thanks! (and sorry if I forgot to mention someone)
|
Thanks! (and sorry if I forgot to mention someone)
|
||||||
|
|
||||||
@@ -108,3 +129,11 @@ References to bug reports and discussions on issues:
|
|||||||
[18] = http://curl.haxx.se/bug/?i=523
|
[18] = http://curl.haxx.se/bug/?i=523
|
||||||
[19] = http://curl.haxx.se/bug/?i=525
|
[19] = http://curl.haxx.se/bug/?i=525
|
||||||
[20] = http://curl.haxx.se/bug/?i=526
|
[20] = http://curl.haxx.se/bug/?i=526
|
||||||
|
[21] = http://curl.haxx.se/bug/?i=532
|
||||||
|
[22] = http://curl.haxx.se/bug/?i=535
|
||||||
|
[23] = http://curl.haxx.se/bug/?i=538
|
||||||
|
[24] = http://curl.haxx.se/bug/?i=534
|
||||||
|
[25] = http://stackoverflow.com/questions/33903982/curl-timecond-none-doesnt-work-how-to-remove-if-modified-since-header
|
||||||
|
[26] = http://curl.haxx.se/mail/lib-2015-11/0088.html
|
||||||
|
[27] = http://curl.haxx.se/bug/?i=530
|
||||||
|
[28] = http://curl.haxx.se/bug/?i=546
|
||||||
|
|||||||
26
configure.ac
26
configure.ac
@@ -3030,6 +3030,31 @@ if test X"$want_h2" != Xno; then
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
dnl **********************************************************************
|
||||||
|
dnl Check for zsh completion path
|
||||||
|
dnl **********************************************************************
|
||||||
|
|
||||||
|
OPT_ZSH_FPATH=default
|
||||||
|
AC_ARG_WITH(zsh-functions-dir,
|
||||||
|
AC_HELP_STRING([--with-zsh-functions-dir=PATH],[Install zsh completions to PATH])
|
||||||
|
AC_HELP_STRING([--without-zsh-functions-dir],[Do not install zsh completions]),
|
||||||
|
[OPT_ZSH_FPATH=$withval])
|
||||||
|
case "$OPT_ZSH_FPATH" in
|
||||||
|
no)
|
||||||
|
dnl --without-zsh-functions-dir option used
|
||||||
|
;;
|
||||||
|
default|yes)
|
||||||
|
dnl --with-zsh-functions-dir option used without path
|
||||||
|
ZSH_FUNCTIONS_DIR="$datarootdir/zsh/site-functions"
|
||||||
|
AC_SUBST(ZSH_FUNCTIONS_DIR)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
dnl --with-zsh-functions-dir option used with path
|
||||||
|
ZSH_FUNCTIONS_DIR="$withval"
|
||||||
|
AC_SUBST(ZSH_FUNCTIONS_DIR)
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
dnl **********************************************************************
|
dnl **********************************************************************
|
||||||
dnl Back to "normal" configuring
|
dnl Back to "normal" configuring
|
||||||
dnl **********************************************************************
|
dnl **********************************************************************
|
||||||
@@ -3797,6 +3822,7 @@ AC_CONFIG_FILES([Makefile \
|
|||||||
include/curl/Makefile \
|
include/curl/Makefile \
|
||||||
src/Makefile \
|
src/Makefile \
|
||||||
lib/Makefile \
|
lib/Makefile \
|
||||||
|
scripts/Makefile \
|
||||||
lib/libcurl.vers \
|
lib/libcurl.vers \
|
||||||
tests/Makefile \
|
tests/Makefile \
|
||||||
tests/certs/Makefile \
|
tests/certs/Makefile \
|
||||||
|
|||||||
@@ -45,10 +45,10 @@ MAN2HTML= roffit < $< >$@
|
|||||||
SUFFIXES = .1 .html .pdf
|
SUFFIXES = .1 .html .pdf
|
||||||
|
|
||||||
html: $(HTMLPAGES)
|
html: $(HTMLPAGES)
|
||||||
cd libcurl; make html
|
cd libcurl && make html
|
||||||
|
|
||||||
pdf: $(PDFPAGES)
|
pdf: $(PDFPAGES)
|
||||||
cd libcurl; make pdf
|
cd libcurl && make pdf
|
||||||
|
|
||||||
.1.html:
|
.1.html:
|
||||||
$(MAN2HTML)
|
$(MAN2HTML)
|
||||||
|
|||||||
20
docs/THANKS
20
docs/THANKS
@@ -262,6 +262,7 @@ Daniel Lee Hwang
|
|||||||
Daniel Melani
|
Daniel Melani
|
||||||
Daniel Mentz
|
Daniel Mentz
|
||||||
Daniel Seither
|
Daniel Seither
|
||||||
|
Daniel Shahaf
|
||||||
Daniel Steinberg
|
Daniel Steinberg
|
||||||
Daniel Stenberg
|
Daniel Stenberg
|
||||||
Daniel Theron
|
Daniel Theron
|
||||||
@@ -275,6 +276,7 @@ Dave May
|
|||||||
Dave Reisner
|
Dave Reisner
|
||||||
Dave Thompson
|
Dave Thompson
|
||||||
Dave Vasilevsky
|
Dave Vasilevsky
|
||||||
|
Davey Shafik
|
||||||
David Bau
|
David Bau
|
||||||
David Binderman
|
David Binderman
|
||||||
David Blaikie
|
David Blaikie
|
||||||
@@ -328,12 +330,14 @@ Dmitry Falko
|
|||||||
Dmitry Kurochkin
|
Dmitry Kurochkin
|
||||||
Dmitry Popov
|
Dmitry Popov
|
||||||
Dmitry Rechkin
|
Dmitry Rechkin
|
||||||
|
Dmitry S. Baikov
|
||||||
Dolbneff A.V
|
Dolbneff A.V
|
||||||
Domenico Andreoli
|
Domenico Andreoli
|
||||||
Dominick Meglio
|
Dominick Meglio
|
||||||
Dominique Leuenberger
|
Dominique Leuenberger
|
||||||
Doug Kaufman
|
Doug Kaufman
|
||||||
Doug Porter
|
Doug Porter
|
||||||
|
Douglas Creager
|
||||||
Douglas E. Wegscheid
|
Douglas E. Wegscheid
|
||||||
Douglas Kilpatrick
|
Douglas Kilpatrick
|
||||||
Douglas R. Horner
|
Douglas R. Horner
|
||||||
@@ -398,6 +402,7 @@ Feist Josselin
|
|||||||
Felix Yan
|
Felix Yan
|
||||||
Felix von Leitner
|
Felix von Leitner
|
||||||
Feng Tu
|
Feng Tu
|
||||||
|
Flavio Medeiros
|
||||||
Florian Schoppmann
|
Florian Schoppmann
|
||||||
Florian Weimer
|
Florian Weimer
|
||||||
Forrest Cahoon
|
Forrest Cahoon
|
||||||
@@ -549,6 +554,7 @@ Jason Liu
|
|||||||
Jason McDonald
|
Jason McDonald
|
||||||
Jason S. Priebe
|
Jason S. Priebe
|
||||||
Javier Barroso
|
Javier Barroso
|
||||||
|
Javier G. Sogo
|
||||||
Jay Austin
|
Jay Austin
|
||||||
Jayesh A Shah
|
Jayesh A Shah
|
||||||
Jaz Fresh
|
Jaz Fresh
|
||||||
@@ -615,6 +621,7 @@ John Janssen
|
|||||||
John Joseph Bachir
|
John Joseph Bachir
|
||||||
John Kelly
|
John Kelly
|
||||||
John Lask
|
John Lask
|
||||||
|
John Levon
|
||||||
John Lightsey
|
John Lightsey
|
||||||
John Marino
|
John Marino
|
||||||
John Marshall
|
John Marshall
|
||||||
@@ -633,6 +640,7 @@ Jon Torrey
|
|||||||
Jon Travis
|
Jon Travis
|
||||||
Jon Turner
|
Jon Turner
|
||||||
Jonas Forsman
|
Jonas Forsman
|
||||||
|
Jonas Minnberg
|
||||||
Jonas Schnelli
|
Jonas Schnelli
|
||||||
Jonatan Lander
|
Jonatan Lander
|
||||||
Jonatan Vela
|
Jonatan Vela
|
||||||
@@ -661,6 +669,7 @@ Julien Nabet
|
|||||||
Julien Royer
|
Julien Royer
|
||||||
Jun-ichiro itojun Hagino
|
Jun-ichiro itojun Hagino
|
||||||
Jurij Smakov
|
Jurij Smakov
|
||||||
|
Justin Ehlert
|
||||||
Justin Fletcher
|
Justin Fletcher
|
||||||
Justin Karneges
|
Justin Karneges
|
||||||
Justin Maggard
|
Justin Maggard
|
||||||
@@ -672,6 +681,7 @@ Kai Sommerfeld
|
|||||||
Kai-Uwe Rommel
|
Kai-Uwe Rommel
|
||||||
Kalle Vahlman
|
Kalle Vahlman
|
||||||
Kamil Dudka
|
Kamil Dudka
|
||||||
|
Kang Lin
|
||||||
Kang-Jin Lee
|
Kang-Jin Lee
|
||||||
Karl Moerder
|
Karl Moerder
|
||||||
Karol Pietrzak
|
Karol Pietrzak
|
||||||
@@ -703,6 +713,7 @@ Krishnendu Majumdar
|
|||||||
Krister Johansen
|
Krister Johansen
|
||||||
Kristian Gunstone
|
Kristian Gunstone
|
||||||
Kristian Köhntopp
|
Kristian Köhntopp
|
||||||
|
Kurt Fankhauser
|
||||||
Kyle J. McKay
|
Kyle J. McKay
|
||||||
Kyle L. Huff
|
Kyle L. Huff
|
||||||
Kyle Sallee
|
Kyle Sallee
|
||||||
@@ -719,6 +730,7 @@ Lars Nilsson
|
|||||||
Lars Torben Wilson
|
Lars Torben Wilson
|
||||||
Lau Hang Kin
|
Lau Hang Kin
|
||||||
Laurent Rabret
|
Laurent Rabret
|
||||||
|
Lauri Kasanen
|
||||||
Legoff Vincent
|
Legoff Vincent
|
||||||
Lehel Bernadt
|
Lehel Bernadt
|
||||||
Leif W
|
Leif W
|
||||||
@@ -747,6 +759,7 @@ Lucas Adamski
|
|||||||
Lucas Pardue
|
Lucas Pardue
|
||||||
Ludek Finstrle
|
Ludek Finstrle
|
||||||
Ludovico Cavedon
|
Ludovico Cavedon
|
||||||
|
Lukas Ruzicka
|
||||||
Lukasz Czekierda
|
Lukasz Czekierda
|
||||||
Luke Amery
|
Luke Amery
|
||||||
Luke Call
|
Luke Call
|
||||||
@@ -855,6 +868,7 @@ Michal Marek
|
|||||||
Michał Fita
|
Michał Fita
|
||||||
Michał Górny
|
Michał Górny
|
||||||
Michał Kowalczyk
|
Michał Kowalczyk
|
||||||
|
Michał Piechowski
|
||||||
Michel Promonet
|
Michel Promonet
|
||||||
Michele Bini
|
Michele Bini
|
||||||
Miguel Angel
|
Miguel Angel
|
||||||
@@ -913,6 +927,7 @@ Nis Jorgensen
|
|||||||
Nobuhiro Ban
|
Nobuhiro Ban
|
||||||
Nodak Sodak
|
Nodak Sodak
|
||||||
Norbert Frese
|
Norbert Frese
|
||||||
|
Norbert Kett
|
||||||
Norbert Novotny
|
Norbert Novotny
|
||||||
Ofer
|
Ofer
|
||||||
Ola Mork
|
Ola Mork
|
||||||
@@ -1049,6 +1064,7 @@ Richard Bramante
|
|||||||
Richard Clayton
|
Richard Clayton
|
||||||
Richard Cooper
|
Richard Cooper
|
||||||
Richard Gorton
|
Richard Gorton
|
||||||
|
Richard Hosking
|
||||||
Richard Michael
|
Richard Michael
|
||||||
Richard Moore
|
Richard Moore
|
||||||
Richard Prescott
|
Richard Prescott
|
||||||
@@ -1122,6 +1138,7 @@ Scott Cantor
|
|||||||
Scott Davis
|
Scott Davis
|
||||||
Scott McCreary
|
Scott McCreary
|
||||||
Sean Boudreau
|
Sean Boudreau
|
||||||
|
Sebastian Pohlschmidt
|
||||||
Sebastian Rasmussen
|
Sebastian Rasmussen
|
||||||
Senthil Raja Velu
|
Senthil Raja Velu
|
||||||
Sergei Nikulov
|
Sergei Nikulov
|
||||||
@@ -1213,7 +1230,7 @@ Tim Costello
|
|||||||
Tim Harder
|
Tim Harder
|
||||||
Tim Heckman
|
Tim Heckman
|
||||||
Tim Newsome
|
Tim Newsome
|
||||||
Tim Ruehsen
|
Tim Rühsen
|
||||||
Tim Sneddon
|
Tim Sneddon
|
||||||
Tim Stack
|
Tim Stack
|
||||||
Tim Starling
|
Tim Starling
|
||||||
@@ -1302,6 +1319,7 @@ Wojciech Zwiefka
|
|||||||
Wouter Van Rooy
|
Wouter Van Rooy
|
||||||
Wu Yongzheng
|
Wu Yongzheng
|
||||||
Xavier Bouchoux
|
Xavier Bouchoux
|
||||||
|
Xiangbin Li
|
||||||
Yaakov Selkowitz
|
Yaakov Selkowitz
|
||||||
Yamada Yasuharu
|
Yamada Yasuharu
|
||||||
Yang Tse
|
Yang Tse
|
||||||
|
|||||||
@@ -51,3 +51,4 @@ s/Viktor Szakats/Viktor Szakáts/
|
|||||||
s/Jonathan Cardoso/Jonathan Cardoso Machado/
|
s/Jonathan Cardoso/Jonathan Cardoso Machado/
|
||||||
s/Linus Nielsen/Linus Nielsen Feltzing/
|
s/Linus Nielsen/Linus Nielsen Feltzing/
|
||||||
s/Todd Ouska$/Todd A Ouska/
|
s/Todd Ouska$/Todd A Ouska/
|
||||||
|
s/Tim Ruehsen/Tim Rühsen/
|
||||||
|
|||||||
97
docs/TODO
97
docs/TODO
@@ -27,11 +27,16 @@
|
|||||||
1.9 Cache negative name resolves
|
1.9 Cache negative name resolves
|
||||||
1.10 Support IDNA2008
|
1.10 Support IDNA2008
|
||||||
1.11 minimize dependencies with dynamicly loaded modules
|
1.11 minimize dependencies with dynamicly loaded modules
|
||||||
|
1.12 have form functions use CURL handle argument
|
||||||
|
1.13 Add CURLOPT_MAIL_CLIENT option
|
||||||
|
1.14 Typesafe curl_easy_setopt()
|
||||||
|
1.15 TCP Fast Open
|
||||||
|
|
||||||
2. libcurl - multi interface
|
2. libcurl - multi interface
|
||||||
2.1 More non-blocking
|
2.1 More non-blocking
|
||||||
2.2 Fix HTTP Pipelining for PUT
|
2.2 Better support for same name resolves
|
||||||
2.3 Better support for same name resolves
|
2.3 Non-blocking curl_multi_remove_handle()
|
||||||
|
2.4 Split connect and authentication process
|
||||||
|
|
||||||
3. Documentation
|
3. Documentation
|
||||||
3.1 Update date and version in man pages
|
3.1 Update date and version in man pages
|
||||||
@@ -141,8 +146,6 @@
|
|||||||
21.6 remove CURLOPT_DNS_USE_GLOBAL_CACHE
|
21.6 remove CURLOPT_DNS_USE_GLOBAL_CACHE
|
||||||
21.7 remove progress meter from libcurl
|
21.7 remove progress meter from libcurl
|
||||||
21.8 remove 'curl_httppost' from public
|
21.8 remove 'curl_httppost' from public
|
||||||
21.9 have form functions use CURL handle argument
|
|
||||||
21.10 Add CURLOPT_MAIL_CLIENT option
|
|
||||||
|
|
||||||
==============================================================================
|
==============================================================================
|
||||||
|
|
||||||
@@ -236,6 +239,51 @@
|
|||||||
app/invoke/used protocols would be necessary to load. See
|
app/invoke/used protocols would be necessary to load. See
|
||||||
https://github.com/bagder/curl/issues/349
|
https://github.com/bagder/curl/issues/349
|
||||||
|
|
||||||
|
1.12 have form functions use CURL handle argument
|
||||||
|
|
||||||
|
curl_formadd() and curl_formget() both currently have no CURL handle
|
||||||
|
argument, but both can use a callback that is set in the easy handle, and
|
||||||
|
thus curl_formget() with callback cannot function without first having
|
||||||
|
curl_easy_perform() (or similar) called - which is hard to grasp and a design
|
||||||
|
mistake.
|
||||||
|
|
||||||
|
The curl_formadd() design can probably also be reconsidered to make it easier
|
||||||
|
to use and less error-prone. Probably easiest by splitting it into several
|
||||||
|
function calls.
|
||||||
|
|
||||||
|
1.13 Add CURLOPT_MAIL_CLIENT option
|
||||||
|
|
||||||
|
Rather than use the URL to specify the mail client string to present in the
|
||||||
|
HELO and EHLO commands, libcurl should support a new CURLOPT specifically for
|
||||||
|
specifying this data as the URL is non-standard and to be honest a bit of a
|
||||||
|
hack ;-)
|
||||||
|
|
||||||
|
Please see the following thread for more information:
|
||||||
|
http://curl.haxx.se/mail/lib-2012-05/0178.html
|
||||||
|
|
||||||
|
1.14 Typesafe curl_easy_setopt()
|
||||||
|
|
||||||
|
One of the most common problems in libcurl using applications is the lack of
|
||||||
|
type checks for curl_easy_setopt() which happens because it accepts varargs
|
||||||
|
and thus can take any type.
|
||||||
|
|
||||||
|
One possible solution to this is to introduce a few different versions of the
|
||||||
|
setopt version for the different kinds of data you can set.
|
||||||
|
|
||||||
|
curl_easy_set_num() - sets a long value
|
||||||
|
|
||||||
|
curl_easy_set_large() - sets a curl_off_t value
|
||||||
|
|
||||||
|
curl_easy_set_ptr() - sets a pointer
|
||||||
|
|
||||||
|
curl_easy_set_cb() - sets a callback PLUS its callback data
|
||||||
|
|
||||||
|
1.15 TCP Fast Open
|
||||||
|
|
||||||
|
RFC 7413 defines how to include data already in the TCP SYN handshake to
|
||||||
|
reduce latency.
|
||||||
|
|
||||||
|
|
||||||
2. libcurl - multi interface
|
2. libcurl - multi interface
|
||||||
|
|
||||||
2.1 More non-blocking
|
2.1 More non-blocking
|
||||||
@@ -252,13 +300,7 @@
|
|||||||
- The "DONE" operation (post transfer protocol-specific actions) for the
|
- The "DONE" operation (post transfer protocol-specific actions) for the
|
||||||
protocols SFTP, SMTP, FTP. Fixing Curl_done() for this is a worthy task.
|
protocols SFTP, SMTP, FTP. Fixing Curl_done() for this is a worthy task.
|
||||||
|
|
||||||
2.2 Fix HTTP Pipelining for PUT
|
2.2 Better support for same name resolves
|
||||||
|
|
||||||
HTTP Pipelining can be a way to greatly enhance performance for multiple
|
|
||||||
serial requests and currently libcurl only supports that for HEAD and GET
|
|
||||||
requests but it should also be possible for PUT.
|
|
||||||
|
|
||||||
2.3 Better support for same name resolves
|
|
||||||
|
|
||||||
If a name resolve has been initiated for name NN and a second easy handle
|
If a name resolve has been initiated for name NN and a second easy handle
|
||||||
wants to resolve that name as well, make it wait for the first resolve to end
|
wants to resolve that name as well, make it wait for the first resolve to end
|
||||||
@@ -266,6 +308,20 @@
|
|||||||
especially needed when adding many simultaneous handles using the same host
|
especially needed when adding many simultaneous handles using the same host
|
||||||
name when the DNS resolver can get flooded.
|
name when the DNS resolver can get flooded.
|
||||||
|
|
||||||
|
2.3 Non-blocking curl_multi_remove_handle()
|
||||||
|
|
||||||
|
The multi interface has a few API calls that assume a blocking behavior, like
|
||||||
|
add_handle() and remove_handle() which limits what we can do internally. The
|
||||||
|
multi API need to be moved even more into a single function that "drives"
|
||||||
|
everything in a non-blocking manner and signals when something is done. A
|
||||||
|
remove or add would then only ask for the action to get started and then
|
||||||
|
multi_perform() etc still be called until the add/remove is completed.
|
||||||
|
|
||||||
|
2.4 Split connect and authentication process
|
||||||
|
|
||||||
|
The multi interface treats the authentication process as part of the connect
|
||||||
|
phase. As such any failures during authentication won't trigger the relevant
|
||||||
|
QUIT or LOGOFF for protocols such as IMAP, POP3 and SMTP.
|
||||||
|
|
||||||
3. Documentation
|
3. Documentation
|
||||||
|
|
||||||
@@ -815,22 +871,3 @@ Currently the SMB authentication uses NTLMv1.
|
|||||||
|
|
||||||
Changing them to return a private handle will benefit the implementation and
|
Changing them to return a private handle will benefit the implementation and
|
||||||
allow us much greater freedoms while still maintaining a solid API and ABI.
|
allow us much greater freedoms while still maintaining a solid API and ABI.
|
||||||
|
|
||||||
21.9 have form functions use CURL handle argument
|
|
||||||
|
|
||||||
curl_formadd() and curl_formget() both currently have no CURL handle
|
|
||||||
argument, but both can use a callback that is set in the easy handle, and
|
|
||||||
thus curl_formget() with callback cannot function without first having
|
|
||||||
curl_easy_perform() (or similar) called - which is hard to grasp and a design
|
|
||||||
mistake.
|
|
||||||
|
|
||||||
21.10 Add CURLOPT_MAIL_CLIENT option
|
|
||||||
|
|
||||||
Rather than use the URL to specify the mail client string to present in the
|
|
||||||
HELO and EHLO commands, libcurl should support a new CURLOPT specifically for
|
|
||||||
specifying this data as the URL is non-standard and to be honest a bit of a
|
|
||||||
hack ;-)
|
|
||||||
|
|
||||||
Please see the following thread for more information:
|
|
||||||
http://curl.haxx.se/mail/lib-2012-05/0178.html
|
|
||||||
|
|
||||||
|
|||||||
4
docs/examples/.gitignore
vendored
4
docs/examples/.gitignore
vendored
@@ -73,3 +73,7 @@ smtp-vrfy
|
|||||||
url2file
|
url2file
|
||||||
usercertinmem
|
usercertinmem
|
||||||
xmlstream
|
xmlstream
|
||||||
|
http2-download
|
||||||
|
http2-serverpush
|
||||||
|
http2-upload
|
||||||
|
imap-lsub
|
||||||
|
|||||||
@@ -32,51 +32,7 @@ actually torture our web site with your tests! Thanks.
|
|||||||
|
|
||||||
EXAMPLES
|
EXAMPLES
|
||||||
|
|
||||||
anyauthput.c - HTTP PUT using "any" authentication method
|
Each example source code file is designed to be and work stand-alone and
|
||||||
cacertinmem.c - Use a built-in PEM certificate to retrieve a https page
|
rather self-explanatory. The examples may at times lack the level of error
|
||||||
cookie_interface.c - shows usage of simple cookie interface
|
checks you need in a real world, but that is then only for the sake of
|
||||||
curlgtk.c - download using a GTK progress bar
|
readability: to make the code smaller and easier to follow.
|
||||||
curlx.c - getting file info from the remote cert data
|
|
||||||
debug.c - showing how to use the debug callback
|
|
||||||
fileupload.c - uploading to a file:// URL
|
|
||||||
fopen.c - fopen() layer that supports opening URLs and files
|
|
||||||
ftpget.c - simple getting a file from FTP
|
|
||||||
ftpgetresp.c - get the response strings from the FTP server
|
|
||||||
ftpupload.c - upload a file to an FTP server
|
|
||||||
ftpuploadresume.c - resume an upload to an FTP server
|
|
||||||
getinfo.c - get the Content-Type from the recent transfer
|
|
||||||
getinmemory.c - download a file to memory only
|
|
||||||
ghiper.c - curl_multi_socket() using code with glib-2
|
|
||||||
hiperfifo.c - downloads all URLs written to the fifo, using
|
|
||||||
curl_multi_socket() and libevent
|
|
||||||
htmltidy.c - download a document and use libtidy to parse the HTML
|
|
||||||
htmltitle.cc - download a HTML file and extract the <title> tag from a HTML
|
|
||||||
page using libxml
|
|
||||||
http-post.c - HTTP POST
|
|
||||||
httpput.c - HTTP PUT a local file
|
|
||||||
https.c - simple HTTPS transfer
|
|
||||||
imap.c - simple IMAP transfer
|
|
||||||
multi-app.c - a multi-interface app
|
|
||||||
multi-debugcallback.c - a multi-interface app using the debug callback
|
|
||||||
multi-double.c - a multi-interface app doing two simultaneous transfers
|
|
||||||
multi-post.c - a multi-interface app doing a multipart formpost
|
|
||||||
multi-single.c - a multi-interface app getting a single file
|
|
||||||
multi-uv.c - a multi-interface app using libuv
|
|
||||||
multithread.c - an example using multi-treading transferring multiple files
|
|
||||||
opensslthreadlock.c - show how to do locking when using OpenSSL multi-threaded
|
|
||||||
persistant.c - request two URLs with a persistent connection
|
|
||||||
pop3s.c - POP3S transfer
|
|
||||||
pop3slist.c - POP3S LIST
|
|
||||||
post-callback.c - send a HTTP POST using a callback
|
|
||||||
postit2.c - send a HTTP multipart formpost
|
|
||||||
sampleconv.c - showing how a program on a non-ASCII platform would invoke
|
|
||||||
callbacks to do its own codeset conversions instead of using
|
|
||||||
the built-in iconv functions in libcurl
|
|
||||||
sepheaders.c - download headers to a separate file
|
|
||||||
simple.c - the most simple download a URL source
|
|
||||||
simplepost.c - HTTP POST
|
|
||||||
simplessl.c - HTTPS example with certificates many options set
|
|
||||||
synctime.c - Sync local time by extracting date from remote HTTP servers
|
|
||||||
url2file.c - download a document and store it in a file
|
|
||||||
xmlstream.c - Stream-parse a document using the streaming Expat parser
|
|
||||||
10-at-a-time.c - Download many files simultaneously, 10 at a time.
|
|
||||||
|
|||||||
@@ -25,6 +25,7 @@
|
|||||||
*/
|
*/
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
/* somewhat unix-specific */
|
/* somewhat unix-specific */
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
|
|||||||
@@ -25,6 +25,7 @@
|
|||||||
*/
|
*/
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
/* somewhat unix-specific */
|
/* somewhat unix-specific */
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
|
|||||||
@@ -25,6 +25,7 @@
|
|||||||
*/
|
*/
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
|
|
||||||
|
|||||||
@@ -19,10 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
/* <DESC>
|
/* <DESC>
|
||||||
* Simple IMAP APPEND use
|
* IMAP example showing how to send e-mails
|
||||||
* </DESC>
|
* </DESC>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to copy an e-mail from one folder to another
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to create a new folder
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to delete a folder
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to obtain information about a folder
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to retreieve e-mails
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example to list the folders within a mailbox
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example to list the subscribed folders
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,7 +19,14 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example using the multi interface
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
/* This is a simple example showing how to fetch mail using libcurl's IMAP
|
/* This is a simple example showing how to fetch mail using libcurl's IMAP
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to perform a noop
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to search for new e-mails
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example using SSL
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example showing how to modify the properties of an e-mail
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* IMAP example using TLS
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example showing how to delete e-mails
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example to list the contents of a mailbox
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,7 +19,14 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example using the multi interface
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
/* This is a simple example showing how to retrieve mail using libcurl's POP3
|
/* This is a simple example showing how to retrieve mail using libcurl's POP3
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example showing how to perform a noop
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example showing how to retrieve e-mails
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example using SSL
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example showing how to obtain message statistics
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example using TLS
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example showing how to retreive only the headers of an e-mail
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* POP3 example to list the contents of a mailbox by unique ID
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,11 +19,17 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* SMTP example showing how to expand an e-mail mailing list
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
/* This is a simple example showing how to expand an email mailing list.
|
/* This is a simple example showing how to expand an e-mail mailing list.
|
||||||
*
|
*
|
||||||
* Notes:
|
* Notes:
|
||||||
*
|
*
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* SMTP example showing how to send e-mails
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* SMTP example using the multi interface
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* SMTP example using SSL
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,6 +19,12 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* SMTP example using TLS
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -19,11 +19,17 @@
|
|||||||
* KIND, either express or implied.
|
* KIND, either express or implied.
|
||||||
*
|
*
|
||||||
***************************************************************************/
|
***************************************************************************/
|
||||||
|
|
||||||
|
/* <DESC>
|
||||||
|
* SMTP example showing how to verify an e-mail address
|
||||||
|
* </DESC>
|
||||||
|
*/
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <curl/curl.h>
|
#include <curl/curl.h>
|
||||||
|
|
||||||
/* This is a simple example showing how to verify an email address from an
|
/* This is a simple example showing how to verify an e-mail address from an
|
||||||
* SMTP server.
|
* SMTP server.
|
||||||
*
|
*
|
||||||
* Notes:
|
* Notes:
|
||||||
|
|||||||
@@ -99,13 +99,13 @@ libcurl-symbols.3: $(srcdir)/symbols-in-versions $(srcdir)/mksymbolsmanpage.pl
|
|||||||
perl $(srcdir)/mksymbolsmanpage.pl < $(srcdir)/symbols-in-versions > $@
|
perl $(srcdir)/mksymbolsmanpage.pl < $(srcdir)/symbols-in-versions > $@
|
||||||
|
|
||||||
html: $(HTMLPAGES)
|
html: $(HTMLPAGES)
|
||||||
cd opts; make html
|
cd opts && make html
|
||||||
|
|
||||||
.3.html:
|
.3.html:
|
||||||
$(MAN2HTML)
|
$(MAN2HTML)
|
||||||
|
|
||||||
pdf: $(PDFPAGES)
|
pdf: $(PDFPAGES)
|
||||||
cd opts; make pdf
|
cd opts && make pdf
|
||||||
|
|
||||||
.3.pdf:
|
.3.pdf:
|
||||||
@(foo=`echo $@ | sed -e 's/\.[0-9]$$//g'`; \
|
@(foo=`echo $@ | sed -e 's/\.[0-9]$$//g'`; \
|
||||||
|
|||||||
@@ -85,7 +85,7 @@ static size_t header_callback(char *buffer, size_t size,
|
|||||||
size_t nitems, void *userdata)
|
size_t nitems, void *userdata)
|
||||||
{
|
{
|
||||||
/* received header is nitems * size long in 'buffer' NOT ZERO TERMINATED */
|
/* received header is nitems * size long in 'buffer' NOT ZERO TERMINATED */
|
||||||
/* 'userdata' is set with CURLOPT_WRITEDATA */
|
/* 'userdata' is set with CURLOPT_HEADERDATA */
|
||||||
return nitems * size;
|
return nitems * size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -416,6 +416,7 @@ CURLcode Curl_resolver_wait_resolv(struct connectdata *conn,
|
|||||||
if(result)
|
if(result)
|
||||||
/* close the connection, since we can't return failure here without
|
/* close the connection, since we can't return failure here without
|
||||||
cleaning up this connection properly.
|
cleaning up this connection properly.
|
||||||
|
TODO: remove this action from here, it is not a name resolver decision.
|
||||||
*/
|
*/
|
||||||
connclose(conn, "c-ares resolve failed");
|
connclose(conn, "c-ares resolve failed");
|
||||||
|
|
||||||
|
|||||||
@@ -83,7 +83,8 @@ Curl_addrinfo *Curl_str2addr(char *dotted, int port);
|
|||||||
Curl_addrinfo *Curl_unix2addr(const char *path);
|
Curl_addrinfo *Curl_unix2addr(const char *path);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(CURLDEBUG) && defined(HAVE_FREEADDRINFO)
|
#if defined(CURLDEBUG) && defined(HAVE_GETADDRINFO) && \
|
||||||
|
defined(HAVE_FREEADDRINFO)
|
||||||
void
|
void
|
||||||
curl_dofreeaddrinfo(struct addrinfo *freethis,
|
curl_dofreeaddrinfo(struct addrinfo *freethis,
|
||||||
int line, const char *source);
|
int line, const char *source);
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2013, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -39,7 +39,7 @@
|
|||||||
*
|
*
|
||||||
* File lib/strdup.c is an exception, given that it provides a strdup
|
* File lib/strdup.c is an exception, given that it provides a strdup
|
||||||
* clone implementation while using malloc. Extra care needed inside
|
* clone implementation while using malloc. Extra care needed inside
|
||||||
* this one.
|
* this one. TODO: revisit this paragraph and related code.
|
||||||
*
|
*
|
||||||
* The need for curl_memory.h inclusion is due to libcurl's feature
|
* The need for curl_memory.h inclusion is due to libcurl's feature
|
||||||
* of allowing library user to provide memory replacement functions,
|
* of allowing library user to provide memory replacement functions,
|
||||||
|
|||||||
@@ -527,6 +527,7 @@
|
|||||||
# define CURLRES_ARES
|
# define CURLRES_ARES
|
||||||
/* now undef the stock libc functions just to avoid them being used */
|
/* now undef the stock libc functions just to avoid them being used */
|
||||||
# undef HAVE_GETADDRINFO
|
# undef HAVE_GETADDRINFO
|
||||||
|
# undef HAVE_FREEADDRINFO
|
||||||
# undef HAVE_GETHOSTBYNAME
|
# undef HAVE_GETHOSTBYNAME
|
||||||
#elif defined(USE_THREADS_POSIX) || defined(USE_THREADS_WIN32)
|
#elif defined(USE_THREADS_POSIX) || defined(USE_THREADS_WIN32)
|
||||||
# define CURLRES_ASYNCH
|
# define CURLRES_ASYNCH
|
||||||
|
|||||||
@@ -646,7 +646,7 @@ static CURLcode wait_or_timeout(struct Curl_multi *multi, struct events *ev)
|
|||||||
return CURLE_RECV_ERROR;
|
return CURLE_RECV_ERROR;
|
||||||
|
|
||||||
if(mcode)
|
if(mcode)
|
||||||
return CURLE_URL_MALFORMAT;
|
return CURLE_URL_MALFORMAT; /* TODO: return a proper error! */
|
||||||
|
|
||||||
/* we don't really care about the "msgs_in_queue" value returned in the
|
/* we don't really care about the "msgs_in_queue" value returned in the
|
||||||
second argument */
|
second argument */
|
||||||
|
|||||||
@@ -3659,7 +3659,7 @@ static CURLcode ftp_do_more(struct connectdata *conn, int *completep)
|
|||||||
if(!conn->bits.tcpconnect[SECONDARYSOCKET]) {
|
if(!conn->bits.tcpconnect[SECONDARYSOCKET]) {
|
||||||
if(conn->tunnel_state[SECONDARYSOCKET] == TUNNEL_CONNECT) {
|
if(conn->tunnel_state[SECONDARYSOCKET] == TUNNEL_CONNECT) {
|
||||||
/* As we're in TUNNEL_CONNECT state now, we know the proxy name and port
|
/* As we're in TUNNEL_CONNECT state now, we know the proxy name and port
|
||||||
aren't used so we blank their arguments. */
|
aren't used so we blank their arguments. TODO: make this nicer */
|
||||||
result = Curl_proxyCONNECT(conn, SECONDARYSOCKET, NULL, 0, FALSE);
|
result = Curl_proxyCONNECT(conn, SECONDARYSOCKET, NULL, 0, FALSE);
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
|
|||||||
26
lib/http.c
26
lib/http.c
@@ -1701,7 +1701,13 @@ CURLcode Curl_add_timecondition(struct SessionHandle *data,
|
|||||||
const struct tm *tm;
|
const struct tm *tm;
|
||||||
char *buf = data->state.buffer;
|
char *buf = data->state.buffer;
|
||||||
struct tm keeptime;
|
struct tm keeptime;
|
||||||
CURLcode result = Curl_gmtime(data->set.timevalue, &keeptime);
|
CURLcode result;
|
||||||
|
|
||||||
|
if(data->set.timecondition == CURL_TIMECOND_NONE)
|
||||||
|
/* no condition was asked for */
|
||||||
|
return CURLE_OK;
|
||||||
|
|
||||||
|
result = Curl_gmtime(data->set.timevalue, &keeptime);
|
||||||
if(result) {
|
if(result) {
|
||||||
failf(data, "Invalid TIMEVALUE");
|
failf(data, "Invalid TIMEVALUE");
|
||||||
return result;
|
return result;
|
||||||
@@ -1727,8 +1733,9 @@ CURLcode Curl_add_timecondition(struct SessionHandle *data,
|
|||||||
tm->tm_sec);
|
tm->tm_sec);
|
||||||
|
|
||||||
switch(data->set.timecondition) {
|
switch(data->set.timecondition) {
|
||||||
case CURL_TIMECOND_IFMODSINCE:
|
|
||||||
default:
|
default:
|
||||||
|
break;
|
||||||
|
case CURL_TIMECOND_IFMODSINCE:
|
||||||
result = Curl_add_bufferf(req_buffer,
|
result = Curl_add_bufferf(req_buffer,
|
||||||
"If-Modified-Since: %s\r\n", buf);
|
"If-Modified-Since: %s\r\n", buf);
|
||||||
break;
|
break;
|
||||||
@@ -2047,7 +2054,10 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
|
|||||||
ptr = strstr(url, conn->host.dispname);
|
ptr = strstr(url, conn->host.dispname);
|
||||||
if(ptr) {
|
if(ptr) {
|
||||||
/* This is where the display name starts in the URL, now replace this
|
/* This is where the display name starts in the URL, now replace this
|
||||||
part with the encoded name. */
|
part with the encoded name. TODO: This method of replacing the host
|
||||||
|
name is rather crude as I believe there's a slight risk that the
|
||||||
|
user has entered a user name or password that contain the host name
|
||||||
|
string. */
|
||||||
size_t currlen = strlen(conn->host.dispname);
|
size_t currlen = strlen(conn->host.dispname);
|
||||||
size_t newlen = strlen(conn->host.name);
|
size_t newlen = strlen(conn->host.name);
|
||||||
size_t urllen = strlen(url);
|
size_t urllen = strlen(url);
|
||||||
@@ -2391,11 +2401,9 @@ CURLcode Curl_http(struct connectdata *conn, bool *done)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if(data->set.timecondition) {
|
result = Curl_add_timecondition(data, req_buffer);
|
||||||
result = Curl_add_timecondition(data, req_buffer);
|
if(result)
|
||||||
if(result)
|
return result;
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
result = Curl_add_custom_headers(conn, FALSE, req_buffer);
|
result = Curl_add_custom_headers(conn, FALSE, req_buffer);
|
||||||
if(result)
|
if(result)
|
||||||
@@ -3329,6 +3337,7 @@ CURLcode Curl_http_readwrite_headers(struct SessionHandle *data,
|
|||||||
conn->httpversion = 11; /* For us, RTSP acts like HTTP 1.1 */
|
conn->httpversion = 11; /* For us, RTSP acts like HTTP 1.1 */
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
/* TODO: do we care about the other cases here? */
|
||||||
nc = 0;
|
nc = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3559,6 +3568,7 @@ CURLcode Curl_http_readwrite_headers(struct SessionHandle *data,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(k->auto_decoding)
|
if(k->auto_decoding)
|
||||||
|
/* TODO: we only support the first mentioned compression for now */
|
||||||
break;
|
break;
|
||||||
|
|
||||||
if(checkprefix("identity", start)) {
|
if(checkprefix("identity", start)) {
|
||||||
|
|||||||
41
lib/http2.c
41
lib/http2.c
@@ -75,6 +75,8 @@ static int http2_perform_getsock(const struct connectdata *conn,
|
|||||||
int bitmap = GETSOCK_BLANK;
|
int bitmap = GETSOCK_BLANK;
|
||||||
(void)numsocks;
|
(void)numsocks;
|
||||||
|
|
||||||
|
/* TODO We should check underlying socket state if it is SSL socket
|
||||||
|
because of renegotiation. */
|
||||||
sock[0] = conn->sock[FIRSTSOCKET];
|
sock[0] = conn->sock[FIRSTSOCKET];
|
||||||
|
|
||||||
if(nghttp2_session_want_read(c->h2))
|
if(nghttp2_session_want_read(c->h2))
|
||||||
@@ -308,8 +310,10 @@ static CURL *duphandle(struct SessionHandle *data)
|
|||||||
(void)Curl_close(second);
|
(void)Curl_close(second);
|
||||||
second = NULL;
|
second = NULL;
|
||||||
}
|
}
|
||||||
else
|
else {
|
||||||
Curl_http2_setup_req(second);
|
Curl_http2_setup_req(second);
|
||||||
|
second->state.stream_weight = data->state.stream_weight;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return second;
|
return second;
|
||||||
@@ -325,12 +329,13 @@ static int push_promise(struct SessionHandle *data,
|
|||||||
frame->promised_stream_id));
|
frame->promised_stream_id));
|
||||||
if(data->multi->push_cb) {
|
if(data->multi->push_cb) {
|
||||||
struct HTTP *stream;
|
struct HTTP *stream;
|
||||||
|
struct HTTP *newstream;
|
||||||
struct curl_pushheaders heads;
|
struct curl_pushheaders heads;
|
||||||
CURLMcode rc;
|
CURLMcode rc;
|
||||||
struct http_conn *httpc;
|
struct http_conn *httpc;
|
||||||
size_t i;
|
size_t i;
|
||||||
/* clone the parent */
|
/* clone the parent */
|
||||||
CURL *newhandle = duphandle(data);
|
struct SessionHandle *newhandle = duphandle(data);
|
||||||
if(!newhandle) {
|
if(!newhandle) {
|
||||||
infof(data, "failed to duplicate handle\n");
|
infof(data, "failed to duplicate handle\n");
|
||||||
rv = 1; /* FAIL HARD */
|
rv = 1; /* FAIL HARD */
|
||||||
@@ -365,6 +370,11 @@ static int push_promise(struct SessionHandle *data,
|
|||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
newstream = newhandle->req.protop;
|
||||||
|
newstream->stream_id = frame->promised_stream_id;
|
||||||
|
newhandle->req.maxdownload = -1;
|
||||||
|
newhandle->req.size = -1;
|
||||||
|
|
||||||
/* approved, add to the multi handle and immediately switch to PERFORM
|
/* approved, add to the multi handle and immediately switch to PERFORM
|
||||||
state with the given connection !*/
|
state with the given connection !*/
|
||||||
rc = Curl_multi_add_perform(data->multi, newhandle, conn);
|
rc = Curl_multi_add_perform(data->multi, newhandle, conn);
|
||||||
@@ -574,7 +584,8 @@ static int on_data_chunk_recv(nghttp2_session *session, uint8_t flags,
|
|||||||
|
|
||||||
/* if we receive data for another handle, wake that up */
|
/* if we receive data for another handle, wake that up */
|
||||||
if(conn->data != data_s)
|
if(conn->data != data_s)
|
||||||
Curl_expire(data_s, 1);
|
Curl_expire(data_s, 1); /* TODO: fix so that this can be set to 0 for
|
||||||
|
immediately? */
|
||||||
|
|
||||||
DEBUGF(infof(data_s, "%zu data received for stream %u "
|
DEBUGF(infof(data_s, "%zu data received for stream %u "
|
||||||
"(%zu left in buffer %p, total %zu)\n",
|
"(%zu left in buffer %p, total %zu)\n",
|
||||||
@@ -790,8 +801,8 @@ static int on_header(nghttp2_session *session, const nghttp2_frame *frame,
|
|||||||
if(conn->data != data_s)
|
if(conn->data != data_s)
|
||||||
Curl_expire(data_s, 1);
|
Curl_expire(data_s, 1);
|
||||||
|
|
||||||
DEBUGF(infof(data_s, "h2 status: HTTP/2 %03d\n",
|
DEBUGF(infof(data_s, "h2 status: HTTP/2 %03d (easy %p)\n",
|
||||||
stream->status_code));
|
stream->status_code, data_s));
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1035,8 +1046,8 @@ static int h2_session_send(struct SessionHandle *data,
|
|||||||
|
|
||||||
h2_pri_spec(data, &pri_spec);
|
h2_pri_spec(data, &pri_spec);
|
||||||
|
|
||||||
DEBUGF(infof(data, "Queuing HTTP/2 PRIORITY frame on stream %u!\n",
|
DEBUGF(infof(data, "Queuing PRIORITY on stream %u (easy %p)\n",
|
||||||
stream->stream_id));
|
stream->stream_id, data));
|
||||||
rv = nghttp2_submit_priority(h2, NGHTTP2_FLAG_NONE, stream->stream_id,
|
rv = nghttp2_submit_priority(h2, NGHTTP2_FLAG_NONE, stream->stream_id,
|
||||||
&pri_spec);
|
&pri_spec);
|
||||||
if(rv)
|
if(rv)
|
||||||
@@ -1090,13 +1101,13 @@ static ssize_t http2_recv(struct connectdata *conn, int sockindex,
|
|||||||
ncopy);
|
ncopy);
|
||||||
stream->nread_header_recvbuf += ncopy;
|
stream->nread_header_recvbuf += ncopy;
|
||||||
|
|
||||||
infof(data, "http2_recv: Got %d bytes from header_recvbuf\n",
|
DEBUGF(infof(data, "http2_recv: Got %d bytes from header_recvbuf\n",
|
||||||
(int)ncopy);
|
(int)ncopy));
|
||||||
return ncopy;
|
return ncopy;
|
||||||
}
|
}
|
||||||
|
|
||||||
infof(data, "http2_recv: %d bytes buffer at %p (stream %u)\n",
|
DEBUGF(infof(data, "http2_recv: easy %p (stream %u)\n",
|
||||||
len, mem, stream->stream_id);
|
data, stream->stream_id));
|
||||||
|
|
||||||
if((data->state.drain) && stream->memlen) {
|
if((data->state.drain) && stream->memlen) {
|
||||||
DEBUGF(infof(data, "http2_recv: DRAIN %zu bytes stream %u!! (%p => %p)\n",
|
DEBUGF(infof(data, "http2_recv: DRAIN %zu bytes stream %u!! (%p => %p)\n",
|
||||||
@@ -1126,8 +1137,8 @@ static ssize_t http2_recv(struct connectdata *conn, int sockindex,
|
|||||||
stream->pausedata = NULL;
|
stream->pausedata = NULL;
|
||||||
stream->pauselen = 0;
|
stream->pauselen = 0;
|
||||||
}
|
}
|
||||||
infof(data, "http2_recv: returns unpaused %zd bytes on stream %u\n",
|
DEBUGF(infof(data, "http2_recv: returns unpaused %zd bytes on stream %u\n",
|
||||||
nread, stream->stream_id);
|
nread, stream->stream_id));
|
||||||
return nread;
|
return nread;
|
||||||
}
|
}
|
||||||
else if(httpc->pause_stream_id) {
|
else if(httpc->pause_stream_id) {
|
||||||
@@ -1208,8 +1219,8 @@ static ssize_t http2_recv(struct connectdata *conn, int sockindex,
|
|||||||
}
|
}
|
||||||
if(stream->memlen) {
|
if(stream->memlen) {
|
||||||
ssize_t retlen = stream->memlen;
|
ssize_t retlen = stream->memlen;
|
||||||
infof(data, "http2_recv: returns %zd for stream %u\n",
|
DEBUGF(infof(data, "http2_recv: returns %zd for stream %u\n",
|
||||||
retlen, stream->stream_id);
|
retlen, stream->stream_id));
|
||||||
stream->memlen = 0;
|
stream->memlen = 0;
|
||||||
|
|
||||||
if(httpc->pause_stream_id == stream->stream_id) {
|
if(httpc->pause_stream_id == stream->stream_id) {
|
||||||
|
|||||||
20
lib/imap.c
20
lib/imap.c
@@ -842,7 +842,7 @@ static CURLcode imap_state_servergreet_resp(struct connectdata *conn,
|
|||||||
|
|
||||||
if(imapcode != 'O') {
|
if(imapcode != 'O') {
|
||||||
failf(data, "Got unexpected imap-server response");
|
failf(data, "Got unexpected imap-server response");
|
||||||
result = CURLE_FTP_WEIRD_SERVER_REPLY;
|
result = CURLE_FTP_WEIRD_SERVER_REPLY; /* TODO: fix this code */
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
result = imap_perform_capability(conn);
|
result = imap_perform_capability(conn);
|
||||||
@@ -1033,7 +1033,7 @@ static CURLcode imap_state_list_resp(struct connectdata *conn, int imapcode,
|
|||||||
line[len] = '\0';
|
line[len] = '\0';
|
||||||
}
|
}
|
||||||
else if(imapcode != 'O')
|
else if(imapcode != 'O')
|
||||||
result = CURLE_QUOTE_ERROR;
|
result = CURLE_QUOTE_ERROR; /* TODO: Fix error code */
|
||||||
else
|
else
|
||||||
/* End of DO phase */
|
/* End of DO phase */
|
||||||
state(conn, IMAP_STOP);
|
state(conn, IMAP_STOP);
|
||||||
@@ -1105,7 +1105,7 @@ static CURLcode imap_state_fetch_resp(struct connectdata *conn, int imapcode,
|
|||||||
if(imapcode != '*') {
|
if(imapcode != '*') {
|
||||||
Curl_pgrsSetDownloadSize(data, -1);
|
Curl_pgrsSetDownloadSize(data, -1);
|
||||||
state(conn, IMAP_STOP);
|
state(conn, IMAP_STOP);
|
||||||
return CURLE_REMOTE_FILE_NOT_FOUND;
|
return CURLE_REMOTE_FILE_NOT_FOUND; /* TODO: Fix error code */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Something like this is received "* 1 FETCH (BODY[TEXT] {2021}\r" so parse
|
/* Something like this is received "* 1 FETCH (BODY[TEXT] {2021}\r" so parse
|
||||||
@@ -1174,7 +1174,7 @@ static CURLcode imap_state_fetch_resp(struct connectdata *conn, int imapcode,
|
|||||||
else {
|
else {
|
||||||
/* We don't know how to parse this line */
|
/* We don't know how to parse this line */
|
||||||
failf(pp->conn->data, "Failed to parse FETCH response.");
|
failf(pp->conn->data, "Failed to parse FETCH response.");
|
||||||
result = CURLE_FTP_WEIRD_SERVER_REPLY;
|
result = CURLE_FTP_WEIRD_SERVER_REPLY; /* TODO: fix this code */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* End of DO phase */
|
/* End of DO phase */
|
||||||
@@ -1193,7 +1193,7 @@ static CURLcode imap_state_fetch_final_resp(struct connectdata *conn,
|
|||||||
(void)instate; /* No use for this yet */
|
(void)instate; /* No use for this yet */
|
||||||
|
|
||||||
if(imapcode != 'O')
|
if(imapcode != 'O')
|
||||||
result = CURLE_FTP_WEIRD_SERVER_REPLY;
|
result = CURLE_FTP_WEIRD_SERVER_REPLY; /* TODO: Fix error code */
|
||||||
else
|
else
|
||||||
/* End of DONE phase */
|
/* End of DONE phase */
|
||||||
state(conn, IMAP_STOP);
|
state(conn, IMAP_STOP);
|
||||||
@@ -1262,7 +1262,7 @@ static CURLcode imap_state_search_resp(struct connectdata *conn, int imapcode,
|
|||||||
line[len] = '\0';
|
line[len] = '\0';
|
||||||
}
|
}
|
||||||
else if(imapcode != 'O')
|
else if(imapcode != 'O')
|
||||||
result = CURLE_QUOTE_ERROR;
|
result = CURLE_QUOTE_ERROR; /* TODO: Fix error code */
|
||||||
else
|
else
|
||||||
/* End of DO phase */
|
/* End of DO phase */
|
||||||
state(conn, IMAP_STOP);
|
state(conn, IMAP_STOP);
|
||||||
@@ -1506,10 +1506,10 @@ static CURLcode imap_done(struct connectdata *conn, CURLcode status,
|
|||||||
|
|
||||||
/* Run the state-machine
|
/* Run the state-machine
|
||||||
|
|
||||||
This _really_ should be using the imap_multi_statemach function but we
|
TODO: when the multi interface is used, this _really_ should be using
|
||||||
have no general support for non-blocking DONE operations. Neither in
|
the imap_multi_statemach function but we have no general support for
|
||||||
the multi state machine and there are Curl_done() invokes on several
|
non-blocking DONE operations, not in the multi state machine and with
|
||||||
places in the code!
|
Curl_done() invokes on several places in the code!
|
||||||
*/
|
*/
|
||||||
if(!result)
|
if(!result)
|
||||||
result = imap_block_statemach(conn);
|
result = imap_block_statemach(conn);
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2012, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -77,7 +77,7 @@ int curlx_nonblock(curl_socket_t sockfd, /* operate on this */
|
|||||||
|
|
||||||
/* Amiga */
|
/* Amiga */
|
||||||
long flags = nonblock ? 1L : 0L;
|
long flags = nonblock ? 1L : 0L;
|
||||||
return IoctlSocket(sockfd, FIONBIO, flags);
|
return IoctlSocket(sockfd, FIONBIO, (char *)&flags);
|
||||||
|
|
||||||
#elif defined(HAVE_SETSOCKOPT_SO_NONBLOCK)
|
#elif defined(HAVE_SETSOCKOPT_SO_NONBLOCK)
|
||||||
|
|
||||||
|
|||||||
@@ -176,7 +176,9 @@ static CURLcode ldap_setup_connection(struct connectdata *conn)
|
|||||||
li->proto = proto;
|
li->proto = proto;
|
||||||
conn->proto.generic = li;
|
conn->proto.generic = li;
|
||||||
connkeep(conn, "OpenLDAP default");
|
connkeep(conn, "OpenLDAP default");
|
||||||
|
/* TODO:
|
||||||
|
* - provide option to choose SASL Binds instead of Simple
|
||||||
|
*/
|
||||||
return CURLE_OK;
|
return CURLE_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -479,6 +481,8 @@ static ssize_t ldap_recv(struct connectdata *conn, int sockindex, char *buf,
|
|||||||
lr->nument++;
|
lr->nument++;
|
||||||
rc = ldap_get_dn_ber(li->ld, ent, &ber, &bv);
|
rc = ldap_get_dn_ber(li->ld, ent, &ber, &bv);
|
||||||
if(rc < 0) {
|
if(rc < 0) {
|
||||||
|
/* TODO: verify that this is really how this return code should be
|
||||||
|
handled */
|
||||||
*err = CURLE_RECV_ERROR;
|
*err = CURLE_RECV_ERROR;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|||||||
18
lib/pop3.c
18
lib/pop3.c
@@ -214,7 +214,7 @@ static const struct Curl_handler Curl_handler_pop3s_proxy = {
|
|||||||
/* SASL parameters for the pop3 protocol */
|
/* SASL parameters for the pop3 protocol */
|
||||||
static const struct SASLproto saslpop3 = {
|
static const struct SASLproto saslpop3 = {
|
||||||
"pop", /* The service name */
|
"pop", /* The service name */
|
||||||
'+', /* Code received when continuation is expected */
|
'*', /* Code received when continuation is expected */
|
||||||
'+', /* Code to receive upon authentication success */
|
'+', /* Code to receive upon authentication success */
|
||||||
255 - 8, /* Maximum initial response length (no max) */
|
255 - 8, /* Maximum initial response length (no max) */
|
||||||
pop3_perform_auth, /* Send authentication command */
|
pop3_perform_auth, /* Send authentication command */
|
||||||
@@ -256,21 +256,29 @@ static bool pop3_endofresp(struct connectdata *conn, char *line, size_t len,
|
|||||||
if(pop3c->state == POP3_CAPA) {
|
if(pop3c->state == POP3_CAPA) {
|
||||||
/* Do we have the terminating line? */
|
/* Do we have the terminating line? */
|
||||||
if(len >= 1 && !memcmp(line, ".", 1))
|
if(len >= 1 && !memcmp(line, ".", 1))
|
||||||
|
/* Treat the response as a success */
|
||||||
*resp = '+';
|
*resp = '+';
|
||||||
else
|
else
|
||||||
|
/* Treat the response as an untagged continuation */
|
||||||
*resp = '*';
|
*resp = '*';
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Do we have a command or continuation response? */
|
/* Do we have a success response? */
|
||||||
if((len >= 3 && !memcmp("+OK", line, 3)) ||
|
if(len >= 3 && !memcmp("+OK", line, 3)) {
|
||||||
(len >= 1 && !memcmp("+", line, 1))) {
|
|
||||||
*resp = '+';
|
*resp = '+';
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Do we have a continuation response? */
|
||||||
|
if(len >= 1 && !memcmp("+", line, 1)) {
|
||||||
|
*resp = '*';
|
||||||
|
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
return FALSE; /* Nothing for us */
|
return FALSE; /* Nothing for us */
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -700,7 +708,7 @@ static CURLcode pop3_state_capa_resp(struct connectdata *conn, int pop3code,
|
|||||||
|
|
||||||
(void)instate; /* no use for this yet */
|
(void)instate; /* no use for this yet */
|
||||||
|
|
||||||
/* Do we have a untagged response? */
|
/* Do we have a untagged continuation response? */
|
||||||
if(pop3code == '*') {
|
if(pop3code == '*') {
|
||||||
/* Does the server support the STLS capability? */
|
/* Does the server support the STLS capability? */
|
||||||
if(len >= 4 && !memcmp(line, "STLS", 4))
|
if(len >= 4 && !memcmp(line, "STLS", 4))
|
||||||
|
|||||||
13
lib/rtsp.c
13
lib/rtsp.c
@@ -42,6 +42,16 @@
|
|||||||
#include "curl_memory.h"
|
#include "curl_memory.h"
|
||||||
#include "memdebug.h"
|
#include "memdebug.h"
|
||||||
|
|
||||||
|
/*
|
||||||
|
* TODO (general)
|
||||||
|
* -incoming server requests
|
||||||
|
* -server CSeq counter
|
||||||
|
* -digest authentication
|
||||||
|
* -connect thru proxy
|
||||||
|
* -pipelining?
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
#define RTP_PKT_CHANNEL(p) ((int)((unsigned char)((p)[1])))
|
#define RTP_PKT_CHANNEL(p) ((int)((unsigned char)((p)[1])))
|
||||||
|
|
||||||
#define RTP_PKT_LENGTH(p) ((((int)((unsigned char)((p)[2]))) << 8) | \
|
#define RTP_PKT_LENGTH(p) ((((int)((unsigned char)((p)[2]))) << 8) | \
|
||||||
@@ -212,6 +222,7 @@ static CURLcode rtsp_done(struct connectdata *conn,
|
|||||||
else if(data->set.rtspreq == RTSPREQ_RECEIVE &&
|
else if(data->set.rtspreq == RTSPREQ_RECEIVE &&
|
||||||
(conn->proto.rtspc.rtp_channel == -1)) {
|
(conn->proto.rtspc.rtp_channel == -1)) {
|
||||||
infof(data, "Got an RTP Receive with a CSeq of %ld\n", CSeq_recv);
|
infof(data, "Got an RTP Receive with a CSeq of %ld\n", CSeq_recv);
|
||||||
|
/* TODO CPC: Server -> Client logic here */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -317,6 +328,8 @@ static CURLcode rtsp_do(struct connectdata *conn, bool *done)
|
|||||||
return CURLE_BAD_FUNCTION_ARGUMENT;
|
return CURLE_BAD_FUNCTION_ARGUMENT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* TODO: proxy? */
|
||||||
|
|
||||||
/* Stream URI. Default to server '*' if not specified */
|
/* Stream URI. Default to server '*' if not specified */
|
||||||
if(data->set.str[STRING_RTSP_STREAM_URI]) {
|
if(data->set.str[STRING_RTSP_STREAM_URI]) {
|
||||||
p_stream_uri = data->set.str[STRING_RTSP_STREAM_URI];
|
p_stream_uri = data->set.str[STRING_RTSP_STREAM_URI];
|
||||||
|
|||||||
@@ -520,11 +520,13 @@ CURLcode Curl_read_plain(curl_socket_t sockfd,
|
|||||||
|
|
||||||
if(-1 == nread) {
|
if(-1 == nread) {
|
||||||
int err = SOCKERRNO;
|
int err = SOCKERRNO;
|
||||||
|
int return_error;
|
||||||
#ifdef USE_WINSOCK
|
#ifdef USE_WINSOCK
|
||||||
if(WSAEWOULDBLOCK == err)
|
return_error = WSAEWOULDBLOCK == err;
|
||||||
#else
|
#else
|
||||||
if((EWOULDBLOCK == err) || (EAGAIN == err) || (EINTR == err))
|
return_error = EWOULDBLOCK == err || EAGAIN == err || EINTR == err;
|
||||||
#endif
|
#endif
|
||||||
|
if(return_error)
|
||||||
return CURLE_AGAIN;
|
return CURLE_AGAIN;
|
||||||
else
|
else
|
||||||
return CURLE_RECV_ERROR;
|
return CURLE_RECV_ERROR;
|
||||||
|
|||||||
@@ -131,7 +131,7 @@ const struct Curl_handler Curl_handler_smbs = {
|
|||||||
defined(__OS400__)
|
defined(__OS400__)
|
||||||
static unsigned short smb_swap16(unsigned short x)
|
static unsigned short smb_swap16(unsigned short x)
|
||||||
{
|
{
|
||||||
return (x << 8) | ((x >> 8) & 0xff);
|
return (unsigned short) ((x << 8) | ((x >> 8) & 0xff));
|
||||||
}
|
}
|
||||||
|
|
||||||
static unsigned int smb_swap32(unsigned int x)
|
static unsigned int smb_swap32(unsigned int x)
|
||||||
@@ -143,12 +143,14 @@ static unsigned int smb_swap32(unsigned int x)
|
|||||||
#ifdef HAVE_LONGLONG
|
#ifdef HAVE_LONGLONG
|
||||||
static unsigned long long smb_swap64(unsigned long long x)
|
static unsigned long long smb_swap64(unsigned long long x)
|
||||||
{
|
{
|
||||||
return ((unsigned long long)smb_swap32(x) << 32) | smb_swap32(x >> 32);
|
return ((unsigned long long) smb_swap32((unsigned int) x) << 32) |
|
||||||
|
smb_swap32((unsigned int) (x >> 32));
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
static unsigned __int64 smb_swap64(unsigned __int64 x)
|
static unsigned __int64 smb_swap64(unsigned __int64 x)
|
||||||
{
|
{
|
||||||
return ((unsigned __int64)smb_swap32(x) << 32) | smb_swap32(x >> 32);
|
return ((unsigned __int64) smb_swap32((unsigned int) x) << 32) |
|
||||||
|
smb_swap32((unsigned int) (x >> 32));
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#else
|
#else
|
||||||
|
|||||||
@@ -1256,8 +1256,10 @@ static CURLcode smtp_done(struct connectdata *conn, CURLcode status,
|
|||||||
|
|
||||||
/* Run the state-machine
|
/* Run the state-machine
|
||||||
|
|
||||||
this should be using the smtp_multi_statemach function but we have no
|
TODO: when the multi interface is used, this _really_ should be using
|
||||||
support for non-blocking DONE operations!
|
the smtp_multi_statemach function but we have no general support for
|
||||||
|
non-blocking DONE operations, not in the multi state machine and with
|
||||||
|
Curl_done() invokes on several places in the code!
|
||||||
*/
|
*/
|
||||||
result = smtp_block_statemach(conn);
|
result = smtp_block_statemach(conn);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -211,7 +211,7 @@ struct Curl_tree *Curl_splaygetbest(struct timeval i,
|
|||||||
/* Deletes the very node we point out from the tree if it's there. Stores a
|
/* Deletes the very node we point out from the tree if it's there. Stores a
|
||||||
* pointer to the new resulting tree in 'newroot'.
|
* pointer to the new resulting tree in 'newroot'.
|
||||||
*
|
*
|
||||||
* Returns zero on success and non-zero on errors!
|
* Returns zero on success and non-zero on errors! TODO: document error codes.
|
||||||
* When returning error, it does not touch the 'newroot' pointer.
|
* When returning error, it does not touch the 'newroot' pointer.
|
||||||
*
|
*
|
||||||
* NOTE: when the last node of the tree is removed, there's no tree left so
|
* NOTE: when the last node of the tree is removed, there's no tree left so
|
||||||
|
|||||||
14
lib/ssh.c
14
lib/ssh.c
@@ -296,6 +296,10 @@ static CURLcode libssh2_session_error_to_CURLE(int err)
|
|||||||
return CURLE_AGAIN;
|
return CURLE_AGAIN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* TODO: map some more of the libssh2 errors to the more appropriate CURLcode
|
||||||
|
error code, and possibly add a few new SSH-related one. We must however
|
||||||
|
not return or even depend on libssh2 errors in the public libcurl API */
|
||||||
|
|
||||||
return CURLE_SSH;
|
return CURLE_SSH;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -2820,8 +2824,10 @@ static CURLcode ssh_connect(struct connectdata *conn, bool *done)
|
|||||||
if(data->set.str[STRING_SSH_KNOWNHOSTS]) {
|
if(data->set.str[STRING_SSH_KNOWNHOSTS]) {
|
||||||
int rc;
|
int rc;
|
||||||
ssh->kh = libssh2_knownhost_init(ssh->ssh_session);
|
ssh->kh = libssh2_knownhost_init(ssh->ssh_session);
|
||||||
if(!ssh->kh)
|
if(!ssh->kh) {
|
||||||
|
/* eeek. TODO: free the ssh_session! */
|
||||||
return CURLE_FAILED_INIT;
|
return CURLE_FAILED_INIT;
|
||||||
|
}
|
||||||
|
|
||||||
/* read all known hosts from there */
|
/* read all known hosts from there */
|
||||||
rc = libssh2_knownhost_readfile(ssh->kh,
|
rc = libssh2_knownhost_readfile(ssh->kh,
|
||||||
@@ -2958,8 +2964,10 @@ static CURLcode ssh_done(struct connectdata *conn, CURLcode status)
|
|||||||
if(!status) {
|
if(!status) {
|
||||||
/* run the state-machine
|
/* run the state-machine
|
||||||
|
|
||||||
This should be using the ssh_multi_statemach function but we have no
|
TODO: when the multi interface is used, this _really_ should be using
|
||||||
support for non-blocking DONE operations!
|
the ssh_multi_statemach function but we have no general support for
|
||||||
|
non-blocking DONE operations, not in the multi state machine and with
|
||||||
|
Curl_done() invokes on several places in the code!
|
||||||
*/
|
*/
|
||||||
result = ssh_block_statemach(conn, FALSE);
|
result = ssh_block_statemach(conn, FALSE);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1220,6 +1220,7 @@ CURLcode telrcv(struct connectdata *conn,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* Escape and send a telnet data block */
|
/* Escape and send a telnet data block */
|
||||||
|
/* TODO: write large chunks of data instead of one byte at a time */
|
||||||
static CURLcode send_telnet_data(struct connectdata *conn,
|
static CURLcode send_telnet_data(struct connectdata *conn,
|
||||||
char *buffer, ssize_t nread)
|
char *buffer, ssize_t nread)
|
||||||
{
|
{
|
||||||
|
|||||||
11
lib/url.c
11
lib/url.c
@@ -6088,8 +6088,13 @@ CURLcode Curl_done(struct connectdata **connp,
|
|||||||
else
|
else
|
||||||
result = status;
|
result = status;
|
||||||
|
|
||||||
if(!result && Curl_pgrsDone(conn))
|
if(CURLE_ABORTED_BY_CALLBACK != result) {
|
||||||
result = CURLE_ABORTED_BY_CALLBACK;
|
/* avoid this if we already aborted by callback to avoid this calling
|
||||||
|
another callback */
|
||||||
|
CURLcode rc = Curl_pgrsDone(conn);
|
||||||
|
if(!result && rc)
|
||||||
|
result = CURLE_ABORTED_BY_CALLBACK;
|
||||||
|
}
|
||||||
|
|
||||||
if((conn->send_pipe->size + conn->recv_pipe->size != 0 &&
|
if((conn->send_pipe->size + conn->recv_pipe->size != 0 &&
|
||||||
!data->set.reuse_forbid &&
|
!data->set.reuse_forbid &&
|
||||||
@@ -6272,6 +6277,8 @@ CURLcode Curl_do(struct connectdata **connp, bool *done)
|
|||||||
* second stage DO state which (wrongly) was introduced to support FTP's
|
* second stage DO state which (wrongly) was introduced to support FTP's
|
||||||
* second connection.
|
* second connection.
|
||||||
*
|
*
|
||||||
|
* TODO: A future libcurl should be able to work away this state.
|
||||||
|
*
|
||||||
* 'complete' can return 0 for incomplete, 1 for done and -1 for go back to
|
* 'complete' can return 0 for incomplete, 1 for done and -1 for go back to
|
||||||
* DOING state there's more work to do!
|
* DOING state there's more work to do!
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -1541,6 +1541,12 @@ static int Curl_gtls_seed(struct SessionHandle *data)
|
|||||||
|
|
||||||
if(!ssl_seeded || data->set.str[STRING_SSL_RANDOM_FILE] ||
|
if(!ssl_seeded || data->set.str[STRING_SSL_RANDOM_FILE] ||
|
||||||
data->set.str[STRING_SSL_EGDSOCKET]) {
|
data->set.str[STRING_SSL_EGDSOCKET]) {
|
||||||
|
|
||||||
|
/* TODO: to a good job seeding the RNG
|
||||||
|
This may involve the gcry_control function and these options:
|
||||||
|
GCRYCTL_SET_RANDOM_SEED_FILE
|
||||||
|
GCRYCTL_SET_RNDEGD_SOCKET
|
||||||
|
*/
|
||||||
ssl_seeded = TRUE;
|
ssl_seeded = TRUE;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@@ -2385,6 +2385,11 @@ static CURLcode get_cert_chain(struct connectdata *conn,
|
|||||||
print_pubkey_BN(dh, priv_key, i);
|
print_pubkey_BN(dh, priv_key, i);
|
||||||
print_pubkey_BN(dh, pub_key, i);
|
print_pubkey_BN(dh, pub_key, i);
|
||||||
break;
|
break;
|
||||||
|
#if 0
|
||||||
|
case EVP_PKEY_EC: /* symbol not present in OpenSSL 0.9.6 */
|
||||||
|
/* left TODO */
|
||||||
|
break;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
EVP_PKEY_free(pubkey);
|
EVP_PKEY_free(pubkey);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1120,7 +1120,22 @@ cleanup:
|
|||||||
*/
|
*/
|
||||||
if(len && !connssl->decdata_offset && connssl->recv_connection_closed &&
|
if(len && !connssl->decdata_offset && connssl->recv_connection_closed &&
|
||||||
!connssl->recv_sspi_close_notify) {
|
!connssl->recv_sspi_close_notify) {
|
||||||
BOOL isWin2k;
|
bool isWin2k = FALSE;
|
||||||
|
|
||||||
|
#if !defined(_WIN32_WINNT) || !defined(_WIN32_WINNT_WIN2K) || \
|
||||||
|
(_WIN32_WINNT < _WIN32_WINNT_WIN2K)
|
||||||
|
OSVERSIONINFO osver;
|
||||||
|
|
||||||
|
memset(&osver, 0, sizeof(osver));
|
||||||
|
osver.dwOSVersionInfoSize = sizeof(osver);
|
||||||
|
|
||||||
|
/* Find out the Windows version */
|
||||||
|
if(GetVersionEx(&osver)) {
|
||||||
|
/* Verify the version number is 5.0 */
|
||||||
|
if(osver.dwMajorVersion == 5 && osver.dwMinorVersion == 0)
|
||||||
|
isWin2k = TRUE;
|
||||||
|
}
|
||||||
|
#else
|
||||||
ULONGLONG cm;
|
ULONGLONG cm;
|
||||||
OSVERSIONINFOEX osver;
|
OSVERSIONINFOEX osver;
|
||||||
|
|
||||||
@@ -1133,10 +1148,11 @@ cleanup:
|
|||||||
cm = VerSetConditionMask(cm, VER_SERVICEPACKMAJOR, VER_GREATER_EQUAL);
|
cm = VerSetConditionMask(cm, VER_SERVICEPACKMAJOR, VER_GREATER_EQUAL);
|
||||||
cm = VerSetConditionMask(cm, VER_SERVICEPACKMINOR, VER_GREATER_EQUAL);
|
cm = VerSetConditionMask(cm, VER_SERVICEPACKMINOR, VER_GREATER_EQUAL);
|
||||||
|
|
||||||
isWin2k = VerifyVersionInfo(&osver,
|
if(VerifyVersionInfo(&osver, (VER_MAJORVERSION | VER_MINORVERSION |
|
||||||
(VER_MAJORVERSION | VER_MINORVERSION |
|
VER_SERVICEPACKMAJOR | VER_SERVICEPACKMINOR),
|
||||||
VER_SERVICEPACKMAJOR | VER_SERVICEPACKMINOR),
|
cm))
|
||||||
cm);
|
isWin2k = TRUE;
|
||||||
|
#endif
|
||||||
|
|
||||||
if(isWin2k && sspi_status == SEC_E_OK)
|
if(isWin2k && sspi_status == SEC_E_OK)
|
||||||
connssl->recv_sspi_close_notify = true;
|
connssl->recv_sspi_close_notify = true;
|
||||||
|
|||||||
@@ -857,6 +857,11 @@ static void do_pubkey(struct SessionHandle * data, int certnum,
|
|||||||
do_pubkey_field(data, certnum, "dh(g)", &elem);
|
do_pubkey_field(data, certnum, "dh(g)", &elem);
|
||||||
do_pubkey_field(data, certnum, "dh(pub_key)", &pk);
|
do_pubkey_field(data, certnum, "dh(pub_key)", &pk);
|
||||||
}
|
}
|
||||||
|
#if 0 /* Patent-encumbered. */
|
||||||
|
else if(curl_strequal(algo, "ecPublicKey")) {
|
||||||
|
/* Left TODO. */
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
CURLcode Curl_extract_certinfo(struct connectdata * conn,
|
CURLcode Curl_extract_certinfo(struct connectdata * conn,
|
||||||
|
|||||||
13
scripts/Makefile.am
Normal file
13
scripts/Makefile.am
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
ZSH_FUNCTIONS_DIR = @ZSH_FUNCTIONS_DIR@
|
||||||
|
PERL = @PERL@
|
||||||
|
|
||||||
|
ZSH_COMPLETION_FUNCTION_FILENAME = _curl
|
||||||
|
|
||||||
|
all-local: $(ZSH_COMPLETION_FUNCTION_FILENAME)
|
||||||
|
|
||||||
|
$(ZSH_COMPLETION_FUNCTION_FILENAME): zsh.pl
|
||||||
|
$(PERL) $< > $@
|
||||||
|
|
||||||
|
install-data-local:
|
||||||
|
$(MKDIR_P) $(DESTDIR)$(ZSH_FUNCTIONS_DIR)
|
||||||
|
$(INSTALL_DATA) $(ZSH_COMPLETION_FUNCTION_FILENAME) $(DESTDIR)$(ZSH_FUNCTIONS_DIR)/$(ZSH_COMPLETION_FUNCTION_FILENAME)
|
||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -117,8 +117,11 @@ void progressbarinit(struct ProgressData *bar,
|
|||||||
if(config->use_resume)
|
if(config->use_resume)
|
||||||
bar->initial_size = config->resume_from;
|
bar->initial_size = config->resume_from;
|
||||||
|
|
||||||
|
/* TODO: get terminal width through ansi escapes or something similar.
|
||||||
|
try to update width when xterm is resized... - 19990617 larsa */
|
||||||
#ifndef __EMX__
|
#ifndef __EMX__
|
||||||
/* OS/2 users most likely won't have this env var set, and besides that
|
/* 20000318 mgs
|
||||||
|
* OS/2 users most likely won't have this env var set, and besides that
|
||||||
* we're using our own way to determine screen width */
|
* we're using our own way to determine screen width */
|
||||||
colp = curlx_getenv("COLUMNS");
|
colp = curlx_getenv("COLUMNS");
|
||||||
if(colp) {
|
if(colp) {
|
||||||
@@ -133,7 +136,8 @@ void progressbarinit(struct ProgressData *bar,
|
|||||||
else
|
else
|
||||||
bar->width = 79;
|
bar->width = 79;
|
||||||
#else
|
#else
|
||||||
/* We use this emx library call to get the screen width, and subtract
|
/* 20000318 mgs
|
||||||
|
* We use this emx library call to get the screen width, and subtract
|
||||||
* one from what we got in order to avoid a problem with the cursor
|
* one from what we got in order to avoid a problem with the cursor
|
||||||
* advancing to the next line if we print a string that is as long as
|
* advancing to the next line if we print a string that is as long as
|
||||||
* the screen is wide. */
|
* the screen is wide. */
|
||||||
|
|||||||
@@ -110,7 +110,7 @@ void customrequest_helper(struct OperationConfig *config, HttpReq req,
|
|||||||
}
|
}
|
||||||
else if(curl_strequal(method, "head")) {
|
else if(curl_strequal(method, "head")) {
|
||||||
warnf(config->global,
|
warnf(config->global,
|
||||||
"Setting custom HTTP method to HEAD may not work the way you "
|
"Setting custom HTTP method to HEAD with -X/--request may not work "
|
||||||
"want.\n");
|
"the way you want. Consider using -I/--head instead.\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -116,6 +116,7 @@ CURLcode curl_easy_perform_ev(CURL *easy);
|
|||||||
static bool is_fatal_error(CURLcode code)
|
static bool is_fatal_error(CURLcode code)
|
||||||
{
|
{
|
||||||
switch(code) {
|
switch(code) {
|
||||||
|
/* TODO: Should CURLE_SSL_CACERT be included as critical error ? */
|
||||||
case CURLE_FAILED_INIT:
|
case CURLE_FAILED_INIT:
|
||||||
case CURLE_OUT_OF_MEMORY:
|
case CURLE_OUT_OF_MEMORY:
|
||||||
case CURLE_UNKNOWN_OPTION:
|
case CURLE_UNKNOWN_OPTION:
|
||||||
@@ -855,6 +856,8 @@ static CURLcode operate_do(struct GlobalConfig *global,
|
|||||||
|
|
||||||
#if !defined(CURL_DISABLE_PROXY)
|
#if !defined(CURL_DISABLE_PROXY)
|
||||||
{
|
{
|
||||||
|
/* TODO: Make this a run-time check instead of compile-time one. */
|
||||||
|
|
||||||
my_setopt_str(curl, CURLOPT_PROXY, config->proxy);
|
my_setopt_str(curl, CURLOPT_PROXY, config->proxy);
|
||||||
my_setopt_str(curl, CURLOPT_PROXYUSERPWD, config->proxyuserpwd);
|
my_setopt_str(curl, CURLOPT_PROXYUSERPWD, config->proxyuserpwd);
|
||||||
|
|
||||||
@@ -1460,6 +1463,10 @@ static CURLcode operate_do(struct GlobalConfig *global,
|
|||||||
* file (or terminal). If we write to a file, we must rewind
|
* file (or terminal). If we write to a file, we must rewind
|
||||||
* or close/re-open the file so that the next attempt starts
|
* or close/re-open the file so that the next attempt starts
|
||||||
* over from the beginning.
|
* over from the beginning.
|
||||||
|
*
|
||||||
|
* TODO: similar action for the upload case. We might need
|
||||||
|
* to start over reading from a previous point if we have
|
||||||
|
* uploaded something when this was returned.
|
||||||
*/
|
*/
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -1534,6 +1541,8 @@ static CURLcode operate_do(struct GlobalConfig *global,
|
|||||||
download was not successful. */
|
download was not successful. */
|
||||||
long response;
|
long response;
|
||||||
if(CURLE_OK == result) {
|
if(CURLE_OK == result) {
|
||||||
|
/* TODO We want to try next resource when download was
|
||||||
|
not successful. How to know that? */
|
||||||
char *effective_url = NULL;
|
char *effective_url = NULL;
|
||||||
curl_easy_getinfo(curl, CURLINFO_EFFECTIVE_URL, &effective_url);
|
curl_easy_getinfo(curl, CURLINFO_EFFECTIVE_URL, &effective_url);
|
||||||
if(effective_url &&
|
if(effective_url &&
|
||||||
@@ -1715,6 +1724,9 @@ static CURLcode operate_do(struct GlobalConfig *global,
|
|||||||
break;
|
break;
|
||||||
mlres = mlres->next;
|
mlres = mlres->next;
|
||||||
if(mlres == NULL)
|
if(mlres == NULL)
|
||||||
|
/* TODO If metalink_next_res is 1 and mlres is NULL,
|
||||||
|
* set res to error code
|
||||||
|
*/
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -426,7 +426,7 @@ static CURLcode checkpasswd(const char *kind, /* for what purpose */
|
|||||||
curlx_msnprintf(prompt, sizeof(prompt),
|
curlx_msnprintf(prompt, sizeof(prompt),
|
||||||
"Enter %s password for user '%s' on URL #%"
|
"Enter %s password for user '%s' on URL #%"
|
||||||
CURL_FORMAT_CURL_OFF_TU ":",
|
CURL_FORMAT_CURL_OFF_TU ":",
|
||||||
kind, *userpwd, i + 1);
|
kind, *userpwd, (curl_off_t) (i + 1));
|
||||||
|
|
||||||
/* get password */
|
/* get password */
|
||||||
getpass_r(prompt, passwd, sizeof(passwd));
|
getpass_r(prompt, passwd, sizeof(passwd));
|
||||||
|
|||||||
@@ -9,8 +9,6 @@
|
|||||||
1512
|
1512
|
||||||
836
|
836
|
||||||
882
|
882
|
||||||
889
|
|
||||||
890
|
|
||||||
938
|
938
|
||||||
# test 1801 causes problems on Mac OS X and github
|
# test 1801 causes problems on Mac OS X and github
|
||||||
# https://github.com/bagder/curl/issues/380
|
# https://github.com/bagder/curl/issues/380
|
||||||
|
|||||||
@@ -86,8 +86,8 @@ test800 test801 test802 test803 test804 test805 test806 test807 test808 \
|
|||||||
test809 test810 test811 test812 test813 test814 test815 test816 test817 \
|
test809 test810 test811 test812 test813 test814 test815 test816 test817 \
|
||||||
test818 test819 test820 test821 test822 test823 test824 test825 test826 \
|
test818 test819 test820 test821 test822 test823 test824 test825 test826 \
|
||||||
test827 test828 test829 test830 test831 test832 test833 test834 test835 \
|
test827 test828 test829 test830 test831 test832 test833 test834 test835 \
|
||||||
test836 test837 test838 test839 test840 test841 test842 test843 test843 \
|
test836 test837 test838 test839 test840 test841 test842 test843 test844 \
|
||||||
test844 \
|
test845 \
|
||||||
\
|
\
|
||||||
test850 test851 test852 test853 test854 test855 test856 test857 test858 \
|
test850 test851 test852 test853 test854 test855 test856 test857 test858 \
|
||||||
test859 test860 test861 test862 test863 test864 test865 test866 test867 \
|
test859 test860 test861 test862 test863 test864 test865 test866 test867 \
|
||||||
|
|||||||
@@ -42,5 +42,8 @@ http://%HOSTIP:%HTTPPORT/1513
|
|||||||
<errorcode>
|
<errorcode>
|
||||||
42
|
42
|
||||||
</errorcode>
|
</errorcode>
|
||||||
|
<stdout>
|
||||||
|
PROGRESSFUNCTION called
|
||||||
|
</stdout>
|
||||||
</verify>
|
</verify>
|
||||||
</testcase>
|
</testcase>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
* | (__| |_| | _ <| |___
|
* | (__| |_| | _ <| |___
|
||||||
* \___|\___/|_| \_\_____|
|
* \___|\___/|_| \_\_____|
|
||||||
*
|
*
|
||||||
* Copyright (C) 1998 - 2014, Daniel Stenberg, <daniel@haxx.se>, et al.
|
* Copyright (C) 1998 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||||
*
|
*
|
||||||
* This software is licensed as described in the file COPYING, which
|
* This software is licensed as described in the file COPYING, which
|
||||||
* you should have received as part of this distribution. The terms
|
* you should have received as part of this distribution. The terms
|
||||||
@@ -41,6 +41,7 @@ static int progressKiller(void *arg,
|
|||||||
(void)dlnow;
|
(void)dlnow;
|
||||||
(void)ultotal;
|
(void)ultotal;
|
||||||
(void)ulnow;
|
(void)ulnow;
|
||||||
|
printf("PROGRESSFUNCTION called\n");
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user