cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: 7.9.2 solaris 2.5.1 compile (was Re: I am amazed...)

From: Götz Babin-Ebell <babinebell_at_trustcenter.de>
Date: Thu, 06 Dec 2001 16:54:29 +0100

Daniel Stenberg wrote:
> On Thu, 6 Dec 2001, Götz Babin-Ebell wrote:
>
> > I was not able to build it under solaris 2.5.1:
> > 1. An include of sys/socket.h seems to require an include of sys/types.h
>
> Where, more specificly, do that needs to be fixed?

please grep the patch for sys/types.h:

lib/memdebug.h (if you compile with --enable-debug)
lib/sentf.c

> > 2. socklen_t and in_addr_t are not known.
> > so src/main.c and src/urlglob.c have to include ../config.h
>
> No. The client code should not use the library's config.h file, it has its
> own in src/config.h. Besides, the client code should not need socklen_t and
> in_addr_t. Why do your compiler require them?

if you configure with --enable-debug, src/main.c and src/urlglob.c
include
lib/memdebug.h.
And in lib/memdebug.h you need at least socklen_t.
If you set the #define socklen_t int from config.h in the src/config.h,
you don't need need the config.h...

> > I was working on my support for OpenSSL ENGINE, so I send my patch now...
>
> Comments on the patch follows, as soon as I've studied it.

My changes in the interface of the library:
1. curl_global_init() got an additional parameter: const char *param:
   a comma seperated list of name=value-pairs,
   for engine support I have added "CRYPTO_ENGINE=<engine>"
2. curl_global_init(): additional flag CURL_GLOBAL_SSL_XTRN:
   signaling the ssl submodule that OpenSSL is initialized external
   and no init is needed.
3. SSLCERTPASSWD is an alias for (new) SSLKEYPASSWD:
   The certificate is public information, you need the pass phrase to
decrypt
   the private key.
4. new SSLCERTTYPE: (string) "DER","PEM","ENG":
   allow to read DER coded cert from file and read cert from engine
   (not supported jet)
5. new SSLKEY: (string):
   set (file) name for private key
6. new SSLKEYTYPE: (see SSLCERTTYPE)
   support to load key from engine (no support for passphrase callback)

changes in the program:
1. additional parameter to support the SSLKEY,... params
2. Since curl_global_init() is called bevore the parameter list is
parsed,
   I added an environmental variable (CURL_INIT_PARAMS).
   Not good but a fast solution ;-)
3. Additional parameter to set passphrase:
   Since now we have a parameter to set the private key, we shouldn't
   set the passphrase with the certificate and I didn't want to stick it
   to the file name...

Bye

Goetz

-- 
Goetz Babin-Ebell, TC TrustCenter AG, http://www.trustcenter.de
Sonninstr. 24-28, 20097 Hamburg, Germany
Tel.: +49-(0)40 80 80 26 -0,  Fax: +49-(0)40 80 80 26 -126

Received on 2001-12-06