Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 329103 - Libraries from both dev-libs/openssl-1.0.0a and -0.9.8-r1 are used at the same time
Summary: Libraries from both dev-libs/openssl-1.0.0a and -0.9.8-r1 are used at the sam...
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-20 11:42 UTC by Dennis Schridde
Modified: 2010-07-20 14:02 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
stacktrace of firefox crash (firefox-crash.log,12.00 KB, text/plain)
2010-07-20 12:42 UTC, Dennis Schridde
Details
stacktrace of firefox crash (with splitdebug) (firefox-crash.log,11.90 KB, text/plain)
2010-07-20 13:23 UTC, Dennis Schridde
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Dennis Schridde 2010-07-20 11:42:08 UTC
Since the update to dev-libs/openssl-1.0.0a it happens that some programs load both the 1.0.0 and the 0.9.8 version of libssl/libcrypto, which causes crashes.

At least media-sound/mumble and www-client/firefox are affected.

Stacktrace of a crashing mumble on my system:
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffdf8d5710 (LWP 6482)]
0x00007ffff73c13e0 in X509_NAME_cmp () from /usr/lib/libcrypto.so.1.0.0
(gdb) bt full
#0  0x00007ffff73c13e0 in X509_NAME_cmp () from /usr/lib/libcrypto.so.1.0.0
No symbol table info available.
#1  0x00007fffe97cca94 in OBJ_bsearch_ex () from /usr/lib/libcrypto.so.0.9.8
No symbol table info available.
#2  0x00007fffe9829d04 in ?? () from /usr/lib/libcrypto.so.0.9.8
No symbol table info available.
#3  0x00007fffe985bc25 in X509_OBJECT_retrieve_match () from /usr/lib/libcrypto.so.0.9.8
No symbol table info available.
#4  0x00007fffe985c33f in X509_STORE_add_cert () from /usr/lib/libcrypto.so.0.9.8
No symbol table info available.
#5  0x00007ffff4ddb37a in QSslSocketBackendPrivate::initSslContext() () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#6  0x00007ffff4ddc849 in QSslSocketBackendPrivate::startClientEncryption() () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#7  0x00007ffff4dd4938 in QSslSocketPrivate::_q_connectedSlot() () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#8  0x00007ffff4dd6bfd in QSslSocket::qt_metacall(QMetaObject::Call, int, void**) () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#9  0x00007ffff4a11a7e in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#10 0x00007ffff4db92be in QAbstractSocketPrivate::fetchConnectionParameters() () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#11 0x00007ffff4dbb070 in QAbstractSocketPrivate::_q_testConnection() () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#12 0x00007ffff4dac261 in QWriteNotifier::event(QEvent*) () from /usr/lib64/qt4/libQtNetwork.so.4
No symbol table info available.
#13 0x00007ffff51eb82c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib64/qt4/libQtGui.so.4
No symbol table info available.
#14 0x00007ffff51f1d0b in QApplication::notify(QObject*, QEvent*) () from /usr/lib64/qt4/libQtGui.so.4
No symbol table info available.
#15 0x00007ffff49feb9b in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#16 0x00007ffff4a27cba in socketNotifierSourceDispatch(_GSource*, int (*)(void*), void*) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#17 0x00007ffff161e8e1 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#18 0x00007ffff1622720 in ?? () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#19 0x00007ffff16228d4 in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
No symbol table info available.
#20 0x00007ffff4a27913 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#21 0x00007ffff49fd532 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#22 0x00007ffff49fd90d in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#23 0x00007ffff490eb8b in QThread::exec() () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#24 0x00000000004cceb7 in ?? ()
---Type <return> to continue, or q <return> to quit---
No symbol table info available.
#25 0x00007ffff4911625 in QThreadPrivate::start(void*) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#26 0x00007ffff4480a1a in start_thread () from /lib/libpthread.so.0
No symbol table info available.
#27 0x00007ffff383f32d in clone () from /lib/libc.so.6
No symbol table info available.

Upstream mumble bug:
http://sourceforge.net/tracker/?func=detail&aid=3031859&group_id=147372&atid=768005

Reproducible: Always
Comment 1 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 11:44:39 UTC
You obviously haven't done "revdep-rebuild --library libssl.so.0.9.8" and "revdep-rebuild --library libcrypto.so.0.9.8" like the openssl postinst message told you to, and like the upstream bug, this is INVALID because of it
Comment 2 Dennis Schridde 2010-07-20 11:47:32 UTC
(In reply to comment #1)
> You obviously haven't done "revdep-rebuild --library libssl.so.0.9.8" and
> "revdep-rebuild --library libcrypto.so.0.9.8" like the openssl postinst message
> told you to, and like the upstream bug, this is INVALID because of it
Thanks for the tip.
Comment 3 Dennis Schridde 2010-07-20 12:06:47 UTC
a) I assumed @preserved-rebuild would already take care of everything revdep-rebuild did. Especially in this case it was "clear", because @preserved-rebuild contained a lot of packages that had to be rebuilt because of them linking against openssl 0.9.8.

b) einfo, ewarn, etc are getting more and more crowded with things I have read again everytime I update the package. Accidentally skipping pieces of information seems inevitable.

c) and reason for reopen:
revdep-rebuild --library libssl.so.0.9.8 ; revdep-rebuild --library libcrypto.so.0.9.8
rebuild only dev-libs/openssl-0.9.8o-r1, app-emulation/emul-linux-x86-baselibs-20100611 and app-emulation/emul-linux-x86-gtklibs-20100611.
The crashes still happen.
Comment 4 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 12:24:16 UTC
What happens if you "emerge -C =dev-libs/openssl-0.9.8o-r1" and make sure the libcrypto.so.0.9.8 and libssl.so.0.9.8 are deleted from /usr/lib. And then try to run those apps?

What I'm after here is the exact binary that is still linked against those, or is trying to dlopen them. Because, I'm suspecting you have some cruft in /usr/local or similar path. Since revdep-rebuild came out clean...
Comment 5 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 12:26:52 UTC
`lddtree` on mumble's binary (or whatever is opening both) might also reveal the source of problem
Comment 6 Dennis Schridde 2010-07-20 12:42:02 UTC
Created attachment 239551 [details]
stacktrace of firefox crash

lddtree /usr/bin/mumble | grep 0.9.8 spit out nothing.

The firefox crash I mentioned earlier is actually a bit different. stacktrace attached. It happens whenever I try to print a website...

Starting mumble after unmerging openssl:0.9.8 results in this:
[New Thread 0x7fffe7017710 (LWP 20921)]
OpenSSL Support: 1
SSL: Added CA certificates from '/etc/ssl/certs/ca-certificates.crt'
No ciphers of at least 128 bit found

Program received signal SIGABRT, Aborted.
0x00007ffff3790545 in raise () from /lib/libc.so.6
(gdb) bt full
#0  0x00007ffff3790545 in raise () from /lib/libc.so.6
No symbol table info available.
#1  0x00007ffff3791d50 in abort () from /lib/libc.so.6
No symbol table info available.
#2  0x00007ffff490964c in qt_message_output(QtMsgType, char const*) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#3  0x00007ffff4909822 in qt_message(QtMsgType, char const*, __va_list_tag*) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#4  0x00007ffff49099c5 in qFatal(char const*, ...) () from /usr/lib64/qt4/libQtCore.so.4
No symbol table info available.
#5  0x00000000004cc7c1 in ?? ()
No symbol table info available.
#6  0x00000000004a73e4 in ?? ()
No symbol table info available.
#7  0x00007ffff377bb8d in __libc_start_main () from /lib/libc.so.6
No symbol table info available.
#8  0x0000000000435029 in ?? ()
No symbol table info available.
#9  0x00007fffffffd9e8 in ?? ()
No symbol table info available.
#10 0x000000000000001c in ?? ()
No symbol table info available.
#11 0x0000000000000001 in ?? ()
No symbol table info available.
#12 0x00007fffffffddc9 in ?? ()
No symbol table info available.
#13 0x0000000000000000 in ?? ()
No symbol table info available.
Comment 7 Dennis Schridde 2010-07-20 12:45:42 UTC
$ grep 0\\.9\\.8 /usr/lib/qt4/*.so
Binary file /usr/lib/qt4/libQtNetwork.so matches
(The string matched is exactly "0.9.8", according to "strings")

So for some reason revdep rebuild fails to detect that qt-network links against openssl 0.9.8?
Comment 8 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 13:07:19 UTC
(In reply to comment #7)
> $ grep 0\\.9\\.8 /usr/lib/qt4/*.so
> Binary file /usr/lib/qt4/libQtNetwork.so matches
> (The string matched is exactly "0.9.8", according to "strings")
> 
> So for some reason revdep rebuild fails to detect that qt-network links against
> openssl 0.9.8?
> 

Got a binary installation of Qt4 somewhere in LDPATH? Try

ldconfig -p |grep QtNetwork

It should only print out the ones in /usr/lib (and possible in /usr/lib32 for emul- pkgs).
Comment 9 Dennis Schridde 2010-07-20 13:12:59 UTC
~ # ldconfig -p |grep QtNetwork
        libQtNetwork.so.4 (libc6,x86-64) => /usr/lib/qt4/libQtNetwork.so.4
        libQtNetwork.so.4 (libc6) => /usr/lib32/qt4/libQtNetwork.so.4
        libQtNetwork.so (libc6,x86-64) => /usr/lib/qt4/libQtNetwork.so
        libQtNetwork.so (libc6) => /usr/lib32/qt4/libQtNetwork.so
Comment 10 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 13:13:29 UTC
And try to recompile x11-libs/qt-core and see if that helps.

And the firefox trace looks rather useless... might want to try "c_rehash
/etc/ssl/certs"
Comment 11 Dennis Schridde 2010-07-20 13:23:27 UTC
Created attachment 239553 [details]
stacktrace of firefox crash (with splitdebug)
Comment 12 Dennis Schridde 2010-07-20 13:24:30 UTC
(In reply to comment #10)
> And try to recompile x11-libs/qt-core and see if that helps.
I already played with that idea, but postponed it to ensure the issue stays reproducable and thus the cause can be found.
Will try it when I have time again, which will be next week.
Comment 13 Dennis Schridde 2010-07-20 13:25:07 UTC
(In reply to comment #11)
> Created an attachment (id=239553) [details]
> stacktrace of firefox crash (with splitdebug)
P.S: This was after running c_rehash.
Comment 14 Jory A. Pratt gentoo-dev 2010-07-20 13:25:56 UTC
(In reply to comment #6)
> Created an attachment (id=239551) [details]
> stacktrace of firefox crash
> 
> lddtree /usr/bin/mumble | grep 0.9.8 spit out nothing.
> 
> The firefox crash I mentioned earlier is actually a bit different. stacktrace
> attached. It happens whenever I try to print a website...
> 
> Starting mumble after unmerging openssl:0.9.8 results in this:
> [New Thread 0x7fffe7017710 (LWP 20921)]
> OpenSSL Support: 1
> SSL: Added CA certificates from '/etc/ssl/certs/ca-certificates.crt'
> No ciphers of at least 128 bit found
> 
> Program received signal SIGABRT, Aborted.
> 0x00007ffff3790545 in raise () from /lib/libc.so.6
> (gdb) bt full
> #0  0x00007ffff3790545 in raise () from /lib/libc.so.6
> No symbol table info available.
> #1  0x00007ffff3791d50 in abort () from /lib/libc.so.6
> No symbol table info available.
> #2  0x00007ffff490964c in qt_message_output(QtMsgType, char const*) () from
> /usr/lib64/qt4/libQtCore.so.4
> No symbol table info available.
> #3  0x00007ffff4909822 in qt_message(QtMsgType, char const*, __va_list_tag*) ()
> from /usr/lib64/qt4/libQtCore.so.4
> No symbol table info available.
> #4  0x00007ffff49099c5 in qFatal(char const*, ...) () from
> /usr/lib64/qt4/libQtCore.so.4
> No symbol table info available.
> #5  0x00000000004cc7c1 in ?? ()
> No symbol table info available.
> #6  0x00000000004a73e4 in ?? ()
> No symbol table info available.
> #7  0x00007ffff377bb8d in __libc_start_main () from /lib/libc.so.6
> No symbol table info available.
> #8  0x0000000000435029 in ?? ()
> No symbol table info available.
> #9  0x00007fffffffd9e8 in ?? ()
> No symbol table info available.
> #10 0x000000000000001c in ?? ()
> No symbol table info available.
> #11 0x0000000000000001 in ?? ()
> No symbol table info available.
> #12 0x00007fffffffddc9 in ?? ()
> No symbol table info available.
> #13 0x0000000000000000 in ?? ()
> No symbol table info available.
> 

This is related to cups, has nothing to do with ssl, cc yourself on bug #325469
Comment 15 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 13:32:55 UTC
(In reply to comment #12)
> (In reply to comment #10)
> > And try to recompile x11-libs/qt-core and see if that helps.
> I already played with that idea, but postponed it to ensure the issue stays
> reproducable and thus the cause can be found.
> Will try it when I have time again, which will be next week.
> 

The Firefox issue, as Jory pointed out in Comment #14 is unrelated.

And after investigating futher, Qt4 doesn't *link* against OpenSSL but it *dlopen*'s it, so revdep-rebuild and preserved-libs won't be able to detect it. This is by design.
You can see this in src/network/ssl/qsslsocket_openssl_symbols.cpp in Qt4 sources.

So I assume rebuilding qt-core will make the problem go away... reopen if not.
Comment 16 Samuli Suominen (RETIRED) gentoo-dev 2010-07-20 13:41:25 UTC
also this propably means we have to do a dummy revision bump of qt-core when openssl-1 goes stable... so people get the rebuild automatically... sigh... :-/
Comment 17 Dennis Schridde 2010-07-20 14:02:44 UTC
rebuilding qt-core solves the problem, lets hope no other lib dlopens ssl 0.9.8...