[openssl-dev] [openssl.org #4066] bug: openssl clean up crash

Haiyang Yin via RT rt at openssl.org
Wed Sep 30 15:06:43 UTC 2015


Hello,
I am using memory-based bio to handle dtls sessions. Crash happened after close notify received and SSL was cleaned up ? OpenSSL version is 1.0.2d. If more detailed information required, pls. let me known.
Thanks,
2015-09-29 22:59:32.968954 [ DEBUG ] [ StunTransManager.cpp ] [ 95 ] StunTransManager::init()
Program received signal SIGSEGV, Segmentation fault.[Switching to Thread 0x7fffe77fe700 (LWP 16074)]0x00007ffff73ced29 in sk_value () from /usr/local/ssl/lib/libcrypto.so.1.0.0(gdb) bt#0  0x00007ffff73ced29 in sk_value () from /usr/local/ssl/lib/libcrypto.so.1.0.0#1  0x00007ffff731f8db in int_free_ex_data () from /usr/local/ssl/lib/libcrypto.so.1.0.0#2  0x00007ffff73c495a in BIO_free () from /usr/local/ssl/lib/libcrypto.so.1.0.0#3  0x00007ffff73c5274 in BIO_free_all () from /usr/local/ssl/lib/libcrypto.so.1.0.0#4  0x00007ffff774df5b in SSL_free () from /usr/local/ssl/lib/libssl.so.1.0.0#5  0x000000000077ca35 in TestDtlsSession::cleanup (this=0x7fffd4000a50) at /home/hyin/projects/intelligent_home_gateway/test/src/TestDtlsSession.cpp:418#6  0x000000000077bcaa in TestDtlsSession::~TestDtlsSession (this=0x7fffd4000a50, __in_chrg=<optimized out>) at /home/hyin/projects/intelligent_home_gateway/test/src/TestDtlsSession.cpp:141#7  0x0000000000786760 in __gnu_cxx::new_allocator<TestDtlsSession>::destroy<TestDtlsSession> (this=0x7fffd4000a50, __p=0x7fffd4000a50) at /usr/include/c++/4.9/ext/new_allocator.h:124#8  0x000000000078671d in std::allocator_traits<std::allocator<TestDtlsSession> >::_S_destroy<TestDtlsSession> (__a=..., __p=0x7fffd4000a50) at /usr/include/c++/4.9/bits/alloc_traits.h:282#9  0x00000000007866c5 in std::allocator_traits<std::allocator<TestDtlsSession> >::destroy<TestDtlsSession> (__a=..., __p=0x7fffd4000a50) at /usr/include/c++/4.9/bits/alloc_traits.h:411#10 0x000000000078656f in std::_Sp_counted_ptr_inplace<TestDtlsSession, std::allocator<TestDtlsSession>, (__gnu_cxx::_Lock_policy)2>::_M_dispose (this=0x7fffd4000a40)    at /usr/include/c++/4.9/bits/shared_ptr_base.h:524#11 0x000000000073a8d6 in std::_Sp_counted_base<(__gnu_cxx::_Lock_policy)2>::_M_release (this=0x7fffd4000a40) at /usr/include/c++/4.9/bits/shared_ptr_base.h:149#12 0x0000000000739a81 in std::__shared_count<(__gnu_cxx::_Lock_policy)2>::~__shared_count (this=0x7fffe77f5738, __in_chrg=<optimized out>) at /usr/include/c++/4.9/bits/shared_ptr_base.h:666#13 0x0000000000783392 in std::__shared_ptr<TestDtlsSession, (__gnu_cxx::_Lock_policy)2>::~__shared_ptr (this=0x7fffe77f5730, __in_chrg=<optimized out>) at /usr/include/c++/4.9/bits/shared_ptr_base.h:914#14 0x00000000007833d2 in std::shared_ptr<TestDtlsSession>::~shared_ptr (this=0x7fffe77f5730, __in_chrg=<optimized out>) at /usr/include/c++/4.9/bits/shared_ptr.h:93#15 0x0000000000781fae in TestStunServer::handleCallback (this=0x7fffffffd230, spTransport=..., sessionMap=..., sender=..., encrypted=0x7fffd8000970 "\025\376", <incomplete sequence \375>,     encryptedLen=39, decrypted=0x7fffe77f59e0 "", decryptedLen=@0x7fffe77f5858: 32768, ready=@0x7fffe77f57c7: false) at /home/hyin/projects/intelligent_home_gateway/test/src/TestStunServer.cpp:637#16 0x00000000007812d6 in TestStunServer::transCallback4 (this=0x7fffffffd230, event=com::purplehyacinth::intellihomegateway::transport::DATA_EVT, sender=...,     data=0x7fffd8000970 "\025\376", <incomplete sequence \375>, dataLen=39) at /home/hyin/projects/intelligent_home_gateway/test/src/TestStunServer.cpp:539#17 0x000000000078594e in std::_Mem_fn<void (TestStunServer::*)(com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long)>::operator()<com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long, void>(TestStunServer*, com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e&&, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*&&, unsigned long&&) const (this=0xc0a070, __object=0x7fffffffd230) at /usr/include/c++/4.9/functional:569#18 0x000000000078539a in std::_Bind<std::_Mem_fn<void (TestStunServer::*)(com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long)> (TestStunServer*, std::_Placeholder<1>, std::_Placeholder<2>, std::_Placeholder<3>, std::_Placeholder<4>)>::__call<void, com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e&&, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*&&, unsigned long&&, 0ul, 1ul, 2ul, 3ul, 4ul>(std::tuple<com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e&&, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*&&, unsigned long&&>&&, std::_Index_tuple<0ul, 1ul, 2ul, 3ul, 4ul>) (    this=0xc0a070, __args=<unknown type in /home/hyin/projects/intelligent_home_gateway/bin/IntelliHomeGatewayTest, CU 0x81488, DIE 0xa0b38>) at /usr/include/c++/4.9/functional:1264#19 0x000000000078479f in std::_Bind<std::_Mem_fn<void (TestStunServer::*)(com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long)> (TestStunServer*, std::_Placeholder<1>, std::_Placeholder<2>, std::_Placeholder<3>, std::_Placeholder<4>)>::operator()<com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long, void>(com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e&&, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*&&, unsigned long&&) (this=0xc0a070) at /usr/include/c++/4.9/functional:1323#20 0x0000000000783f59 in std::_Function_handler<void (com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long), std::_Bind<std::_Mem_fn<void (TestStunServer::*)(com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long)> (TestStunServer*, std::_Placeholder<1>, std::_Placeholder<2>, std::_Placeholder<3>, std::_Placeholder<4>)> >::_M_invoke(std::_Any_data const&, com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long) (__functor=...,     __args#0=com::purplehyacinth::intellihomegateway::transport::DATA_EVT, __args#1=..., __args#2=0x7fffd8000970 "\025\376", <incomplete sequence \375>, __args#3=39)    at /usr/include/c++/4.9/functional:2039#21 0x00000000008928b6 in std::function<void (com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long)>::operator()(com::purplehyacinth::intellihomegateway::transport::CallbackEvent_e, com::purplehyacinth::intellihomegateway::transport::TransportAddress const&, char const*, unsigned long) const (this=0xc2d508, __args#0=com::purplehyacinth::intellihomegateway::transport::DATA_EVT, __args#1=..., __args#2=0x7fffd8000970 "\025\376", <incomplete sequence \375>, __args#3=39)    at /usr/include/c++/4.9/functional:2439#22 0x0000000000891841 in com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher::dispatch (this=0xc2d500)    at /home/hyin/projects/intelligent_home_gateway/src/com/purplehyacinth/intellihomegateway/transport/ServerCallbackDispatcher.cpp:173#23 0x000000000089684b in std::_Mem_fn<bool (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher::*)()>::operator()<, void>(com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher*) const (this=0xc086d0, __object=0xc2d500) at /usr/include/c++/4.9/functional:569#24 0x00000000008967c2 in std::_Bind<std::_Mem_fn<bool (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher::*)()> (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher*)>::__call<bool, , 0ul>(std::tuple<>&&, std::_Index_tuple<0ul>) (this=0xc086d0,     __args=<unknown type in /home/hyin/projects/intelligent_home_gateway/bin/IntelliHomeGatewayTest, CU 0x6aa2e7, DIE 0x6c96ef>) at /usr/include/c++/4.9/functional:1264#25 0x0000000000896664 in std::_Bind<std::_Mem_fn<bool (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher::*)()> (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher*)>::operator()<, bool>() (this=0xc086d0) at /usr/include/c++/4.9/functional:1323#26 0x0000000000896481 in std::_Function_handler<bool (), std::_Bind<std::_Mem_fn<bool (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher::*)()> (com::purplehyacinth::intellihomegateway::transport::ServerCallbackDispatcher*)> >::_M_invoke(std::_Any_data const&) (__functor=...) at /usr/include/c++/4.9/functional:2025#27 0x000000000081dc9e in std::function<bool ()>::operator()() const (this=0xc3daa0) at /usr/include/c++/4.9/functional:2439---Type <return> to continue, or q <return> to quit---  #28 0x000000000081d630 in com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::run() (this=0xc3daa0)    at /home/hyin/projects/intelligent_home_gateway/inc/common/ScopedThread.hpp:209#29 0x000000000081fdbf in std::_Mem_fn<void (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::*)()>::operator()<, void>(com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >*) const (this=0xc3dbe8, __object=0xc3daa0) at /usr/include/c++/4.9/functional:569#30 0x000000000081fd28 in std::_Bind<std::_Mem_fn<void (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::*)()> (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >*)>::__call<void, , 0ul>(std::tuple<>&&, std::_Index_tuple<0ul>) (this=0xc3dbe8,     __args=<unknown type in /home/hyin/projects/intelligent_home_gateway/bin/IntelliHomeGatewayTest, CU 0x39f627, DIE 0x3b467a>) at /usr/include/c++/4.9/functional:1264#31 0x000000000081fca2 in std::_Bind<std::_Mem_fn<void (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::*)()> (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >*)>::operator()<, void>() (this=0xc3dbe8) at /usr/include/c++/4.9/functional:1323#32 0x000000000081fbf6 in std::_Bind_simple<std::_Bind<std::_Mem_fn<void (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::*)()> (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >*)> ()>::_M_invoke<>(std::_Index_tuple<>) (this=0xc3dbe8) at /usr/include/c++/4.9/functional:1700#33 0x000000000081fae3 in std::_Bind_simple<std::_Bind<std::_Mem_fn<void (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::*)()> (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >*)> ()>::operator()() (this=0xc3dbe8) at /usr/include/c++/4.9/functional:1688#34 0x000000000081f9fc in std::thread::_Impl<std::_Bind_simple<std::_Bind<std::_Mem_fn<void (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >::*)()> (com::purplehyacinth::intellihomegateway::common::ScopedThread<std::function<bool ()> >*)> ()> >::_M_run() (this=0xc3dbd0) at /usr/include/c++/4.9/thread:115#35 0x00007ffff6dbce40 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6#36 0x00007ffff7bc4182 in start_thread (arg=0x7fffe77fe700) at pthread_create.c:312#37 0x00007ffff651d47d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:111(gdb) (gdb) (gdb) (gdb) q

-------------- next part --------------
_______________________________________________
openssl-bugs-mod mailing list
openssl-bugs-mod at openssl.org
https://mta.openssl.org/mailman/listinfo/openssl-bugs-mod


More information about the openssl-dev mailing list