Bug 46745 - ab.c error : undefined reference to `BIO_set_callback' (apache 2.2.11/openssl-0.9.8j)
Summary: ab.c error : undefined reference to `BIO_set_callback' (apache 2.2.11/openss...
Status: RESOLVED LATER
Alias: None
Product: Apache httpd-2
Classification: Unclassified
Component: mod_ssl (show other bugs)
Version: 2.2.11
Hardware: PC Linux
: P2 major (vote)
Target Milestone: ---
Assignee: Apache HTTPD Bugs Mailing List
URL:
Keywords: MassUpdate
Depends on:
Blocks:
 
Reported: 2009-02-20 03:41 UTC by Gourav Shah
Modified: 2018-11-07 21:08 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gourav Shah 2009-02-20 03:41:48 UTC
----------------------------------
Environment

apache:    apache 2.2.11
openssl:   openssl-0.9.8j 
os:        openSUSE 10.2 (X86-64)
kernel:    apache 2.2.11/openssl-0.9.8j
gcc:       gcc (GCC) 4.1.2 20061115
----------------------------------
configure options

--enable-so --enable-mods-shared=all --prefix=/d0 --with-mpm=worker  --enable-threads --with-berkeley-db=/d0 --enable-modules="ssl proxy cache disk-cache mem-cache info" --with-ssl=/d0

----------------------------------
Error Message: 

ab.c:(.text+0xf1): undefined reference to `BIO_get_callback_arg'
.libs/ab.o: In function `start_connect':
ab.c:(.text+0x3452): undefined reference to `BIO_set_callback'
ab.c:(.text+0x3465): undefined reference to `BIO_set_callback_arg'
.libs/ab.o: In function `main':
ab.c:(.text+0x5e3a): undefined reference to `SSL_CTX_set_info_callback'
collect2: ld returned 1 exit status
make[2]: *** [ab] Error 1
make[2]: Leaving directory `/d0/httpd-2.2.11/support'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/d0/httpd-2.2.11/support'
make: *** [all-recursive] Error 1

-----------------------------------
Comment 1 Vadym Chepkov 2009-07-27 14:58:04 UTC
It happens with openssl 0.9.8k as well.
Is there any solution, the bug has been open for more then 5 months already?
Comment 2 peter.schlaf 2010-04-06 17:11:12 UTC
my system:

SLES 10 SP2 (x86_64)
apache-2.2.15
openssl-1.0.0


An older openssl version (0.9.8a) was already installed, so I had to put the new version into a different directory (/usr/local/openssl).

Compiled openssl with:

  ./config -fPIC --prefix=/usr/local/openssl shared && make && make install

Making the new libs public:

  cd /etc/ld.so.conf.d/
  echo "/usr/local/openssl/lib64" > openssl.conf
  ldconfig -v

Next I tried to compile apache with:

  ./configure --prefix=/usr/local/apache --enable-mods-shared=all --with-ssl=/usr/local/openssl --enable-ssl=shared --enable-proxy=shared && make


and ran into the same error message described above.

After some research I found that this problem seems to be a "lib versus lib64" issue. openssl has installed the new libs in "/usr/local/openssl/lib64" and apache configure includes only a directory "/usr/local/openssl/lib" (which doesn't exist).
Finally, in /usr/local/openssl I did a "ln -s lib64/ lib" and was able to compile apache successfully without any error messages. After that, apache started with: 
"Apache/2.2.15 (Unix) mod_ssl/2.2.15 OpenSSL/1.0.0 DAV/2 configured -- resuming normal operations" and performs perfectly since then.
Comment 3 Steve Kelem 2013-09-10 04:12:32 UTC
I'm seeing the same problem on apache 2.4.6, Ubuntu Linux 13.04 x86_64.

I compiled and installed openssl-1.0.0g. It installed in /usr/local/ssl. (Not openssl!) That directory has a lib directory, but no lib64 directory.

I configured httpd with:
./configure \
--cache-file=/usr/share/config/config.cache \
--prefix=/usr/local/apache2 \
--enable-dav \
--enable-http \
--enable-imagemap \
--enable-modules=all \
--enable-modules=most \
--enable-so \
--enable-unixd \
--prefix=/usr/local/apache2 \
--with-included-apr \
--with-included-apr-util \
--with-included-iconv \
--enable-ssl \
--enable-ssl-staticlib-deps \
--with-crypto \
--enable-session-crypto \
--with-ssl=/usr/local/ssl \
--with-mysql \
--with-perl 

and I've tried commenting out the lines with "ssl" and "crypto", but still get the errors:

make[2]: Entering directory `/local/usr/local/src/httpd-2.4.6/support'
/usr/local/src/httpd-2.4.6/srclib/apr/libtool --silent --mode=link gcc -std=gnu99  -g -O2 -pthread     \
	         -o ab  ab.lo       /usr/local/src/httpd-2.4.6/srclib/apr-util/libaprutil-1.la -lexpat /usr/local/src/httpd-2.4.6/srclib/apr/libapr-1.la -luuid -lrt -lcrypt -lpthread -ldl -lm
ab.o: In function `ssl_print_cb':
/usr/local/src/httpd-2.4.6/support/ab.c:445: undefined reference to `BIO_get_callback_arg'
/usr/local/src/httpd-2.4.6/support/ab.c:455: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:457: undefined reference to `BIO_dump'
ab.o: In function `ssl_print_cert_info':
/usr/local/src/httpd-2.4.6/support/ab.c:549: undefined reference to `ASN1_INTEGER_get'
/usr/local/src/httpd-2.4.6/support/ab.c:549: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:550: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:551: undefined reference to `ASN1_UTCTIME_print'
/usr/local/src/httpd-2.4.6/support/ab.c:552: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:554: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:555: undefined reference to `ASN1_UTCTIME_print'
/usr/local/src/httpd-2.4.6/support/ab.c:556: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:558: undefined reference to `X509_get_pubkey'
/usr/local/src/httpd-2.4.6/support/ab.c:559: undefined reference to `EVP_PKEY_bits'
/usr/local/src/httpd-2.4.6/support/ab.c:559: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:561: undefined reference to `EVP_PKEY_free'
/usr/local/src/httpd-2.4.6/support/ab.c:563: undefined reference to `X509_get_issuer_name'
/usr/local/src/httpd-2.4.6/support/ab.c:564: undefined reference to `X509_NAME_oneline'
/usr/local/src/httpd-2.4.6/support/ab.c:565: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:567: undefined reference to `X509_get_subject_name'
/usr/local/src/httpd-2.4.6/support/ab.c:568: undefined reference to `X509_NAME_oneline'
/usr/local/src/httpd-2.4.6/support/ab.c:569: undefined reference to `BIO_printf'
/usr/local/src/httpd-2.4.6/support/ab.c:572: undefined reference to `X509_get_ext_count'
/usr/local/src/httpd-2.4.6/support/ab.c:572: undefined reference to `BIO_printf'
Comment 4 William A. Rowe Jr. 2018-11-07 21:08:57 UTC
Please help us to refine our list of open and current defects; this is a mass update of old and inactive Bugzilla reports which reflect user error, already resolved defects, and still-existing defects in httpd.

As repeatedly announced, the Apache HTTP Server Project has discontinued all development and patch review of the 2.2.x series of releases. The final release 2.2.34 was published in July 2017, and no further evaluation of bug reports or security risks will be considered or published for 2.2.x releases. All reports older than 2.4.x have been updated to status RESOLVED/LATER; no further action is expected unless the report still applies to a current version of httpd.

If your report represented a question or confusion about how to use an httpd feature, an unexpected server behavior, problems building or installing httpd, or working with an external component (a third party module, browser etc.) we ask you to start by bringing your question to the User Support and Discussion mailing list, see [https://httpd.apache.org/lists.html#http-users] for details. Include a link to this Bugzilla report for completeness with your question.

If your report was clearly a defect in httpd or a feature request, we ask that you retest using a modern httpd release (2.4.33 or later) released in the past year. If it can be reproduced, please reopen this bug and change the Version field above to the httpd version you have reconfirmed with.

Your help in identifying defects or enhancements still applicable to the current httpd server software release is greatly appreciated.