I'm still looking for help with this problem.

The uBSec support works in 0.9.7g with static linking.
The uBSec support works in 0.9.7g with shared libraries. 
The uBSec support works in 0.9.8  with static linking.
The uBSec support fails in 0.9.8  with shared libraries.

Here's a matrix:

------------------------------------------------
Version  | ./config (static) | ./config shared |
------------------------------------------------
0.9.7.g  | Works             | Works           |
------------------------------------------------
0.9.8    | Works             | Fails!           |
------------------------------------------------

Here is the command line I use to build the test program:

gcc -o test test.c  -I include ./libssl.a ./libcrypto.a -ldl

It feels like this is such a major bug that it can't possibly be real,
and I must be doing something wrong.

Can somebody help me?

Thanks.






-----Original Message-----
From: Martin Del Vecchio 
Sent: Thursday, October 20, 2005 10:42 AM
To: '[email protected]'
Subject: Problem using Broadcom uBSec engine in 0.9.8

I am using OpenSSL on Linux in a shared library environment (./config
shared).

I am trying to load support for the Broadcom uBSec engine.  Here is a
test program:

int main (int argc, char *argv[])
   {  ENGINE *Engine;

   SSL_library_init();
   SSL_load_error_strings();
   OpenSSL_add_all_algorithms();
   ENGINE_load_ubsec();

   // See if we can find the ubsec engine
   Engine = ENGINE_by_id ("ubsec");
   if (Engine)
      printf ("ENGINE_by_id() found uBSec at %p.\n", Engine);
   else
      printf ("ENGINE_by_id() did not find UBSec.\n");

   return (0);
   }

I compile and link this file (test.c) with OpenSSL 0.9.7g:

   gcc -o test test.c -I include ./libssl.so ./libcrypto.so

I run it, and it reports that it finds the uBSec engine.

I try this with OpenSSL 0.9.8 and I get a link error:

   /tmp/ccuqAevP.o(.text+0x12c): In function `main': 
   : undefined reference to `ENGINE_load_ubsec'
   collect2: ld returned 1 exit status

This symbol is in e_ubsec.c, but when I include the corresponding .o
file, I get the same error.  That's because the symbol is not defined in
e_ubsec.o, because it is inside a conditional:

   #ifdef OPENSSL_NO_DYNAMIC_ENGINE

This symbol is not defined, because I chose the shared-library
configuration.

How can I use the built-in uBSec engine in a shared-library environment?

Thanks.


   
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
Development Mailing List                       [email protected]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to