Loading include/curl/curl.h +13 −0 Original line number Diff line number Diff line Loading @@ -613,6 +613,12 @@ typedef enum { #define CURLPROTO_DICT (1<<9) #define CURLPROTO_FILE (1<<10) #define CURLPROTO_TFTP (1<<11) #define CURLPROTO_IMAP (1<<12) #define CURLPROTO_IMAPS (1<<13) #define CURLPROTO_POP3 (1<<14) #define CURLPROTO_POP3S (1<<15) #define CURLPROTO_SMTP (1<<16) #define CURLPROTO_SMTPS (1<<17) #define CURLPROTO_ALL (~0) /* enable everything */ /* long may be 32 or 64 bits, but we should never depend on anything else Loading Loading @@ -1028,6 +1034,7 @@ typedef enum { essentially places a demand on the FTP server to acknowledge commands in a timely manner. */ CINIT(FTP_RESPONSE_TIMEOUT, LONG, 112), #define CURLOPT_SERVER_RESPONSE_TIMEOUT CURLOPT_FTP_RESPONSE_TIMEOUT /* Set this option to one of the CURL_IPRESOLVE_* defines (see below) to tell libcurl to resolve names to those IP versions only. This only has Loading Loading @@ -1272,6 +1279,12 @@ typedef enum { /* set the SSH host key callback custom pointer */ CINIT(SSH_KEYDATA, OBJECTPOINT, 185), /* set the SMTP mail originator */ CINIT(MAIL_FROM, OBJECTPOINT, 186), /* set the SMTP mail receiver(s) */ CINIT(MAIL_RCPT, OBJECTPOINT, 187), CURLOPT_LASTENTRY /* the last unused */ } CURLoption; Loading lib/Makefile.am +1 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ VCPROJ = libcurl.vcproj DOCS = README.encoding README.memoryleak README.ares README.curlx \ README.hostip README.multi_socket README.httpauth README.pipelining \ README.curl_off_t README.cmake README.curl_off_t README.cmake README.pingpong CMAKE_DIST = CMakeLists.txt curl_config.h.cmake Loading lib/Makefile.inc +2 −3 Original line number Diff line number Diff line Loading @@ -11,7 +11,7 @@ CSOURCES = file.c timeval.c base64.c hostip.c progress.c formdata.c \ inet_ntop.c parsedate.c select.c gtls.c sslgen.c tftp.c splay.c \ strdup.c socks.c ssh.c nss.c qssl.c rawstr.c curl_addrinfo.c \ socks_gssapi.c socks_sspi.c curl_sspi.c slist.c nonblock.c \ curl_memrchr.c curl_memrchr.c imap.c pop3.c smtp.c pingpong.c HHEADERS = arpa_telnet.h netrc.h file.h timeval.h qssl.h hostip.h \ progress.h formdata.h cookie.h http.h sendf.h ftp.h url.h dict.h \ Loading @@ -23,5 +23,4 @@ HHEADERS = arpa_telnet.h netrc.h file.h timeval.h qssl.h hostip.h \ transfer.h select.h easyif.h multiif.h parsedate.h sslgen.h gtls.h \ tftp.h sockaddr.h splay.h strdup.h setup_once.h socks.h ssh.h nssg.h \ curl_base64.h rawstr.h curl_addrinfo.h curl_sspi.h slist.h nonblock.h \ curl_memrchr.h curl_memrchr.h imap.h pop3.h smtp.h pingpong.h lib/README.pingpong 0 → 100644 +30 −0 Original line number Diff line number Diff line Date: December 5, 2009 Pingpong ======== Pingpong is just my (Daniel's) jestful collective name on the protocols that share a very similar kind of back-and-forth procedure with command and responses to and from the server. FTP was previously the only protocol in that family that libcurl supported, but when POP3, IMAP and SMTP joined the team I moved some of the internals into a separate pingpong module to be easier to get used by all these protocols to reduce code duplication and ease code re-use between these protocols. FTP In 7.20.0 we converted code to use the new pingpong code from previously having been all "native" FTP code. POP3 There's no support in the documented URL format to specify the exact mail to get, but we support that as the path specified in the URL. IMAP SMTP There's no official URL syntax defined for SMTP, but we use only the generic one and we provide two additional libcurl options to specify receivers and sender of the actual mail. lib/ftp.c +100 −495 File changed.Preview size limit exceeded, changes collapsed. Show changes Loading
include/curl/curl.h +13 −0 Original line number Diff line number Diff line Loading @@ -613,6 +613,12 @@ typedef enum { #define CURLPROTO_DICT (1<<9) #define CURLPROTO_FILE (1<<10) #define CURLPROTO_TFTP (1<<11) #define CURLPROTO_IMAP (1<<12) #define CURLPROTO_IMAPS (1<<13) #define CURLPROTO_POP3 (1<<14) #define CURLPROTO_POP3S (1<<15) #define CURLPROTO_SMTP (1<<16) #define CURLPROTO_SMTPS (1<<17) #define CURLPROTO_ALL (~0) /* enable everything */ /* long may be 32 or 64 bits, but we should never depend on anything else Loading Loading @@ -1028,6 +1034,7 @@ typedef enum { essentially places a demand on the FTP server to acknowledge commands in a timely manner. */ CINIT(FTP_RESPONSE_TIMEOUT, LONG, 112), #define CURLOPT_SERVER_RESPONSE_TIMEOUT CURLOPT_FTP_RESPONSE_TIMEOUT /* Set this option to one of the CURL_IPRESOLVE_* defines (see below) to tell libcurl to resolve names to those IP versions only. This only has Loading Loading @@ -1272,6 +1279,12 @@ typedef enum { /* set the SSH host key callback custom pointer */ CINIT(SSH_KEYDATA, OBJECTPOINT, 185), /* set the SMTP mail originator */ CINIT(MAIL_FROM, OBJECTPOINT, 186), /* set the SMTP mail receiver(s) */ CINIT(MAIL_RCPT, OBJECTPOINT, 187), CURLOPT_LASTENTRY /* the last unused */ } CURLoption; Loading
lib/Makefile.am +1 −1 Original line number Diff line number Diff line Loading @@ -27,7 +27,7 @@ VCPROJ = libcurl.vcproj DOCS = README.encoding README.memoryleak README.ares README.curlx \ README.hostip README.multi_socket README.httpauth README.pipelining \ README.curl_off_t README.cmake README.curl_off_t README.cmake README.pingpong CMAKE_DIST = CMakeLists.txt curl_config.h.cmake Loading
lib/Makefile.inc +2 −3 Original line number Diff line number Diff line Loading @@ -11,7 +11,7 @@ CSOURCES = file.c timeval.c base64.c hostip.c progress.c formdata.c \ inet_ntop.c parsedate.c select.c gtls.c sslgen.c tftp.c splay.c \ strdup.c socks.c ssh.c nss.c qssl.c rawstr.c curl_addrinfo.c \ socks_gssapi.c socks_sspi.c curl_sspi.c slist.c nonblock.c \ curl_memrchr.c curl_memrchr.c imap.c pop3.c smtp.c pingpong.c HHEADERS = arpa_telnet.h netrc.h file.h timeval.h qssl.h hostip.h \ progress.h formdata.h cookie.h http.h sendf.h ftp.h url.h dict.h \ Loading @@ -23,5 +23,4 @@ HHEADERS = arpa_telnet.h netrc.h file.h timeval.h qssl.h hostip.h \ transfer.h select.h easyif.h multiif.h parsedate.h sslgen.h gtls.h \ tftp.h sockaddr.h splay.h strdup.h setup_once.h socks.h ssh.h nssg.h \ curl_base64.h rawstr.h curl_addrinfo.h curl_sspi.h slist.h nonblock.h \ curl_memrchr.h curl_memrchr.h imap.h pop3.h smtp.h pingpong.h
lib/README.pingpong 0 → 100644 +30 −0 Original line number Diff line number Diff line Date: December 5, 2009 Pingpong ======== Pingpong is just my (Daniel's) jestful collective name on the protocols that share a very similar kind of back-and-forth procedure with command and responses to and from the server. FTP was previously the only protocol in that family that libcurl supported, but when POP3, IMAP and SMTP joined the team I moved some of the internals into a separate pingpong module to be easier to get used by all these protocols to reduce code duplication and ease code re-use between these protocols. FTP In 7.20.0 we converted code to use the new pingpong code from previously having been all "native" FTP code. POP3 There's no support in the documented URL format to specify the exact mail to get, but we support that as the path specified in the URL. IMAP SMTP There's no official URL syntax defined for SMTP, but we use only the generic one and we provide two additional libcurl options to specify receivers and sender of the actual mail.