Notes on libCURL, OpenSSL, ZLIB, and SSH2 for Windows, Linux, and Macintosh

(by Brian Wilson, 7/12/07)

0. Uhhh, Why Write this Webpage?

It's to keep my thoughts straight, and maybe help out the random crazy developer like myself who might be trying to understand this world.

1. How are the libraries of libCURL, OpenSSL, ZLIB, and SSH2 related?

While each of these libraries can be used alone (and are developed by different groups), it turns out they are ACTUALLY VERY TIGHTLY INTEGRATED and I believe should be one distribution and library.  For example, libCURL cannot fetch an HTTPS url unless it links with OpenSSL. Here is a layer-cake diagram of the relationships between the libraries libCURL, OpenSSL, ZLIB, and SSH2:

     

As shown in the diagram above, the most stand-alone of any of the libraries is ZLIB which doesn't know about any of the other libraries, so I drew it in at the very bottom.  OpenSSL comes next, it can either be compiled alone, or with a flag to use ZLIB.  I have no idea why OpenSSL would use ZLIB, this sounds kind of strange to me, but this is the situation.  If you leave SSH2 out of the mix, libCURL is very functional with HTTP and even works with FTP, but cannot transfer files using SFTP (which is the default FTP service enabled on RedHat Linux and thus very very useful).

2. What happens if you compile OpenSSL *without* ZLIB, but libCURL *with* ZLIB?

I doubt anybody really knows.  I count somewhere around 24 different combinations of ways to compile the above libraries in various combinations on any one platform.  I use them on Windows, Macintosh, and Linux, so that makes for 72 variations in my environment.  You can compile them either shared libraries or static libraries, so that is 144 combinations.  Blech! 

3. libCURL - References, Authors, Current Rev Numbers

libCURL website: http://curl.haxx.se/libcurl/
libCURL Authors: Daniel Stenberg (and he seems generous with credit to many other contributers)
libCURL Functionality: convenient library allowing a 'C' application to post and get HTTP and HTTPS URLs (also FTP, SFTP, etc)
libCURL Current Release (as of 7/12/07): "libCURL 7.16.4"

4. ZLIB - References, Authors, Current Rev Numbers

ZLIB website: http://www.zlib.net
ZLIB Authors: Jean-loup Gailly (compression) and Mark Adler (decompression)
ZLIB Functionality: compression, namely the zip format
ZLIB Current Release (as of 7/12/07): "ZlibVersion 1.2.3"

5. OpenSSL - References, Authors, Current Rev Numbers

OpenSSL website: http://www.openssl.org/
OpenSSL Authors: Seems to be based on a library by Eric A. Young and Tim J. Hudson.
OpenSSL Functionality: SSL/TLS encryption (like in HTTPS transfers)
OpenSSL Current Release (as of 7/12/07): "OpenSSL Version 0.9.8e"
Brian's (my) Additional OpenSSL Notes: http://www.ski-epic.com/2007_notes_on_openssl/index.html

6. SSH2 - References, Authors, Current Rev Numbers

SSH2 website: http://www.libssh2.org
SSH2 Authors: Daniel Stenberg (the main guy who writes libCURL!), Sara Golemon, and a bunch of others.
SSH2 Functionality: implements the SSH2 protocol, which specifically is used in SFTP and SCP
SSH2 Current Release (as of 7/12/07): "libssh2-0.15"

 

Click Here to return to Ski-Epic Home, and Click Here to return to Random Stuff in Brian's Life