Ruby 1.8.3 OpenSSL on Red Hat problems

It’s been a bad week for me and Red Hat Enterprise 4 WS. Latest thing that doesn’t work seems to be Ruby 1.8.3’s OpenSSL module. On my PowerMac:

mark@eagle:~$ openssl
OpenSSL> version
OpenSSL 0.9.7g 11 Apr 2005
OpenSSL> mark@eagle:~$
mark@eagle:~$
mark@eagle:~$ irb
irb(main):001:0> require "openssl"
=> true

No problemo. So I was able to do a gem update --system and move to rubygems 8.11.

On my RHEL4WS box, however, doing the gem update produced this:

symbol lookup error: /usr/local/ruby/1.8.3/lib/ruby/1.8/i686-linux/openssl.so: undefined symbol: OpenSSL_add_all_algorithms

RubyGems system software updated

Except, it actually blew up, and now I can’t run gem at all. Or anything to do with OpenSSL, actually:

[root@serv02 rubygems-0.8.10]# gem
ruby: symbol lookup error:
 /usr/local/ruby/1.8.3/lib/ruby/1.8/i686-linux/openssl.so:
 undefined symbol: OpenSSL_add_all_algorithms

[root@serv02 rubygems-0.8.10]# irb
irb(main):001:0> require "openssl"
irb: symbol lookup error: /usr/local/ruby/1.8.3/lib/ruby/1.8/i686-linux/openssl.so:
 undefined symbol: OpenSSL_add_all_algorithms

Hmrf. I figured maybe I didn’t have openssl-dev or something, but everything I can think seems to look good:

[root@serv02 ~]# rpm -qa|grep -i openssl
pyOpenSSL-0.6-1.p23
openssl-0.9.7a-43.2
openssl-devel-0.9.7a-43.2
xmlsec1-openssl-1.2.6-3
[root@serv02 ~]# openssl
OpenSSL> version
OpenSSL 0.9.7a Feb 19 2003
^D
[root@serv02 ~]# ldd /usr/local/ruby/1.8.3/lib/ruby/1.8/i686-linux/openssl.so
       libssl.so.4 => /lib/libssl.so.4 (0x00aee000)
       libcrypto.so.4 => /lib/libcrypto.so.4 (0x007bf000)
       libdl.so.2 => /lib/libdl.so.2 (0x00f89000)
       libcrypt.so.1 => /lib/libcrypt.so.1 (0x009a4000)
       libm.so.6 => /lib/tls/libm.so.6 (0x00747000)
       libc.so.6 => /lib/tls/libc.so.6 (0x00111000)
       libgssapi_krb5.so.2 => /usr/lib/libgssapi_krb5.so.2 (0x00f8e000)
       libkrb5.so.3 => /usr/lib/libkrb5.so.3 (0x0023a000)
       libcom_err.so.2 => /lib/libcom_err.so.2 (0x00d25000)
       libk5crypto.so.3 => /usr/lib/libk5crypto.so.3 (0x00e01000)
       libresolv.so.2 => /lib/libresolv.so.2 (0x00e89000)
       libz.so.1 => /usr/lib/libz.so.1 (0x00b7a000)
       /lib/ld-linux.so.2 (0x00a77000)

Double hmrf. It looks like the stock OpenSSL is broken, only it can’t be. Other programs are making OpenSSL calls and they’re not busted. More investigation required.


About this entry