ethereum / aleth

Aleth – Ethereum C++ client, tools and libraries
GNU General Public License v3.0
3.97k stars 2.17k forks source link

Buffer overflow in testeth --filltests #4031

Open chfast opened 7 years ago

chfast commented 7 years ago
=================================================================
==13617==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x6020000daf58 at pc 0x55917e2b9aee bp 0x7f27890c9930 sp 0x7f27890c9920
READ of size 8 at 0x6020000daf58 thread T1
    #0 0x55917e2b9aed in dev::test::ImportTest::exportTest(std::vector<unsigned char, std::allocator<unsigned char> > const&) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/ImportTest.cpp:579
    #1 0x55917e21b3da in dev::test::doStateTests(json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:71
    #2 0x55917e161386 in std::_Function_handler<void (json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool), void (*)(json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool)>::_M_invoke(std::_Any_data const&, json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool&&) /usr/include/c++/6/functional:1740
    #3 0x55917e16aff2 in std::function<void (json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool)>::operator()(json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool) const /usr/include/c++/6/functional:2136
    #4 0x55917e305bc8 in dev::test::executeTests(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::function<void (json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool)>, bool) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/TestHelper.cpp:460
    #5 0x55917e21d61c in generaltestfixture::fillAllFilesInFolder(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:131
    #6 0x55917e21dc93 in generaltestfixture::generaltestfixture() /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:110
    #7 0x55917e209dad in StateTestsGeneral::stRevertTest::stRevertTest() /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:178
    #8 0x55917e209dad in stRevertTest_invoker /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:178
    #9 0x55917e19902e in boost::detail::function::void_function_invoker0<void (*)(), void>::invoke(boost::detail::function::function_buffer&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:118
    #10 0x55917e38481d in boost::function0<void>::operator()() const /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:771
    #11 0x55917e38481d in boost::detail::forward::operator()() /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:1300
    #12 0x55917e38481d in boost::detail::function::function_obj_invoker0<boost::detail::forward, int>::invoke(boost::detail::function::function_buffer&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:138
    #13 0x55917e336271 in boost::function0<int>::operator()() const /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:771
    #14 0x55917e336271 in int boost::detail::do_invoke<boost::shared_ptr<boost::detail::translator_holder_base>, boost::function<int ()> >(boost::shared_ptr<boost::detail::translator_holder_base> const&, boost::function<int ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:281
    #15 0x55917e336271 in boost::execution_monitor::catch_signals(boost::function<int ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:864
    #16 0x55917e33c87b in boost::execution_monitor::execute(boost::function<int ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:1203
    #17 0x55917e33d620 in boost::execution_monitor::vexecute(boost::function<void ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:1309
    #18 0x55917e347588 in boost::unit_test::unit_test_monitor_t::execute_and_translate(boost::function<void ()> const&, unsigned int) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/unit_test_monitor.ipp:46
    #19 0x55917e3c0c51 in boost::unit_test::framework::state::execute_test_tree(unsigned long, unsigned int, boost::unit_test::framework::state::random_generator_helper const*) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:717
    #20 0x55917e3c0d67 in boost::unit_test::framework::state::execute_test_tree(unsigned long, unsigned int, boost::unit_test::framework::state::random_generator_helper const*) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:666
    #21 0x55917e3c0d67 in boost::unit_test::framework::state::execute_test_tree(unsigned long, unsigned int, boost::unit_test::framework::state::random_generator_helper const*) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:666
    #22 0x55917e3601ab in boost::unit_test::framework::run(unsigned long, bool) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:1442
    #23 0x55917e37685c in boost::unit_test::unit_test_main(boost::unit_test::test_suite* (*)(int, char**), int, char**) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/unit_test_main.ipp:231
    #24 0x55917e37a1c7 in int std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>::_M_invoke<0ul, 1ul, 2ul>(std::_Index_tuple<0ul, 1ul, 2ul>) /usr/include/c++/6/functional:1400
    #25 0x55917e37a1c7 in std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>::operator()() /usr/include/c++/6/functional:1389
    #26 0x55917e37a1c7 in std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<int>, std::__future_base::_Result_base::_Deleter>, std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int>::operator()() const /usr/include/c++/6/future:1325
    #27 0x55917e37a1c7 in std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> (), std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<int>, std::__future_base::_Result_base::_Deleter>, std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int> >::_M_invoke(std::_Any_data const&) /usr/include/c++/6/functional:1726
    #28 0x55917e38458b in std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>::operator()() const /usr/include/c++/6/functional:2136
    #29 0x55917e384646 in std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*) /usr/include/c++/6/future:533
    #30 0x55917e377b87 in void std::__invoke_impl<void, void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::__invoke_memfun_deref, void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) /usr/include/c++/6/functional:235
    #31 0x55917e377b87 in std::result_of<void (std::__future_base::_State_baseV2::* const&(std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&))(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>::type std::__invoke<void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) /usr/include/c++/6/functional:260
    #32 0x55917e377b87 in decltype (__invoke((*this)._M_pmf, (forward<std::__future_base::_State_baseV2*>)({parm#1}), (forward<std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*>)({parm#1}), (forward<bool*>)({parm#1}))) std::_Mem_fn_base<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), true>::operator()<std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) const /usr/include/c++/6/functional:613
    #33 0x55917e377b87 in void std::_Bind_simple<std::_Mem_fn<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> (std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>::_M_invoke<0ul, 1ul, 2ul>(std::_Index_tuple<0ul, 1ul, 2ul>) /usr/include/c++/6/functional:1400
    #34 0x55917e377b87 in std::_Bind_simple<std::_Mem_fn<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> (std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>::operator()() /usr/include/c++/6/functional:1389
    #35 0x55917e377b87 in void std::__once_call_impl<std::_Bind_simple<std::_Mem_fn<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> (std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> >() /usr/include/c++/6/mutex:587
    #36 0x7f278d36ac18 in __pthread_once_slow (/lib/x86_64-linux-gnu/libpthread.so.0+0xec18)
    #37 0x55917e387743 in void std::call_once<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::once_flag&, void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) (/home/chfast/Projects/ethereum/cpp-ethereum/build/debug/test/testeth+0x576743)
    #38 0x55917e3c5886 in std::__future_base::_State_baseV2::_M_set_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool) /usr/include/c++/6/future:393
    #39 0x55917e3c5886 in std::__future_base::_Async_state_impl<std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int>::_Async_state_impl(std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>&&)::{lambda()#1}::operator()() const /usr/include/c++/6/future:1664
    #40 0x55917e3c5886 in void std::_Bind_simple<std::__future_base::_Async_state_impl<std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int>::_Async_state_impl(std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>&&)::{lambda()#1} ()>::_M_invoke<>(std::_Index_tuple<>) /usr/include/c++/6/functional:1400
    #41 0x55917e3c5886 in std::_Bind_simple<std::__future_base::_Async_state_impl<std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int>::_Async_state_impl(std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>&&)::{lambda()#1} ()>::operator()() /usr/include/c++/6/functional:1389
    #42 0x55917e3c5886 in std::thread::_State_impl<std::_Bind_simple<std::__future_base::_Async_state_impl<std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int>::_Async_state_impl(std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>&&)::{lambda()#1} ()> >::_M_run() /usr/include/c++/6/thread:196
    #43 0x7f278ca1750e  (/usr/lib/x86_64-linux-gnu/libstdc++.so.6+0xbb50e)
    #44 0x7f278d3636c9 in start_thread (/lib/x86_64-linux-gnu/libpthread.so.0+0x76c9)
    #45 0x7f278c17d0ae in __clone (/lib/x86_64-linux-gnu/libc.so.6+0x1080ae)

0x6020000daf58 is located 0 bytes to the right of 8-byte region [0x6020000daf50,0x6020000daf58)
allocated by thread T1 here:
    #0 0x7f278d641ef0 in operator new(unsigned long) (/usr/lib/x86_64-linux-gnu/libasan.so.3+0xc7ef0)
    #1 0x55917e176878 in __gnu_cxx::new_allocator<unsigned long>::allocate(unsigned long, void const*) /usr/include/c++/6/ext/new_allocator.h:104
    #2 0x55917e176878 in std::allocator_traits<std::allocator<unsigned long> >::allocate(std::allocator<unsigned long>&, unsigned long) /usr/include/c++/6/bits/alloc_traits.h:416
    #3 0x55917e176878 in std::_Vector_base<unsigned long, std::allocator<unsigned long> >::_M_allocate(unsigned long) /usr/include/c++/6/bits/stl_vector.h:170
    #4 0x55917e176878 in void std::vector<unsigned long, std::allocator<unsigned long> >::_M_emplace_back_aux<unsigned long const&>(unsigned long const&) /usr/include/c++/6/bits/vector.tcc:412
    #5 0x55917e2b7f2d in std::vector<unsigned long, std::allocator<unsigned long> >::push_back(unsigned long const&) /usr/include/c++/6/bits/stl_vector.h:924
    #6 0x55917e2b7f2d in dev::test::ImportTest::checkGeneralTestSectionSearch(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const, json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > > const&, std::vector<unsigned long, std::allocator<unsigned long> >&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::pair<dev::test::ImportTest::transactionToExecute, std::pair<dev::eth::State, std::unordered_map<dev::FixedHash<20u>, dev::eth::AccountMask, std::hash<dev::FixedHash<20u> >, std::equal_to<dev::FixedHash<20u> >, std::allocator<std::pair<dev::FixedHash<20u> const, dev::eth::AccountMask> > > > >*) const /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/ImportTest.cpp:534
    #7 0x55917e2b9064 in dev::test::ImportTest::checkGeneralTestSection(std::map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >, std::less<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > >, std::allocator<std::pair<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const, json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > > > > const&, std::vector<unsigned long, std::allocator<unsigned long> >&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&) const /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/ImportTest.cpp:467
    #8 0x55917e2b9525 in dev::test::ImportTest::exportTest(std::vector<unsigned char, std::allocator<unsigned char> > const&) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/ImportTest.cpp:563
    #9 0x55917e21b3da in dev::test::doStateTests(json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:71
    #10 0x55917e161386 in std::_Function_handler<void (json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool), void (*)(json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool)>::_M_invoke(std::_Any_data const&, json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool&&) /usr/include/c++/6/functional:1740
    #11 0x55917e16aff2 in std::function<void (json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool)>::operator()(json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool) const /usr/include/c++/6/functional:2136
    #12 0x55917e305bc8 in dev::test::executeTests(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, std::function<void (json_spirit::Value_impl<json_spirit::Config_map<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&, bool)>, bool) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/TestHelper.cpp:460
    #13 0x55917e21d61c in generaltestfixture::fillAllFilesInFolder(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >) /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:131
    #14 0x55917e21dc93 in generaltestfixture::generaltestfixture() /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:110
    #15 0x55917e209dad in StateTestsGeneral::stRevertTest::stRevertTest() /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:178
    #16 0x55917e209dad in stRevertTest_invoker /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/jsontests/StateTests.cpp:178
    #17 0x55917e19902e in boost::detail::function::void_function_invoker0<void (*)(), void>::invoke(boost::detail::function::function_buffer&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:118
    #18 0x55917e38481d in boost::function0<void>::operator()() const /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:771
    #19 0x55917e38481d in boost::detail::forward::operator()() /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:1300
    #20 0x55917e38481d in boost::detail::function::function_obj_invoker0<boost::detail::forward, int>::invoke(boost::detail::function::function_buffer&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:138
    #21 0x55917e336271 in boost::function0<int>::operator()() const /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/function/function_template.hpp:771
    #22 0x55917e336271 in int boost::detail::do_invoke<boost::shared_ptr<boost::detail::translator_holder_base>, boost::function<int ()> >(boost::shared_ptr<boost::detail::translator_holder_base> const&, boost::function<int ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:281
    #23 0x55917e336271 in boost::execution_monitor::catch_signals(boost::function<int ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:864
    #24 0x55917e33c87b in boost::execution_monitor::execute(boost::function<int ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:1203
    #25 0x55917e33d620 in boost::execution_monitor::vexecute(boost::function<void ()> const&) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/execution_monitor.ipp:1309
    #26 0x55917e347588 in boost::unit_test::unit_test_monitor_t::execute_and_translate(boost::function<void ()> const&, unsigned int) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/unit_test_monitor.ipp:46
    #27 0x55917e3c0c51 in boost::unit_test::framework::state::execute_test_tree(unsigned long, unsigned int, boost::unit_test::framework::state::random_generator_helper const*) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:717
    #28 0x55917e3c0d67 in boost::unit_test::framework::state::execute_test_tree(unsigned long, unsigned int, boost::unit_test::framework::state::random_generator_helper const*) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:666
    #29 0x55917e3c0d67 in boost::unit_test::framework::state::execute_test_tree(unsigned long, unsigned int, boost::unit_test::framework::state::random_generator_helper const*) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:666
    #30 0x55917e3601ab in boost::unit_test::framework::run(unsigned long, bool) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/framework.ipp:1442
    #31 0x55917e37685c in boost::unit_test::unit_test_main(boost::unit_test::test_suite* (*)(int, char**), int, char**) /home/chfast/Projects/ethereum/cpp-ethereum/deps/src/boost/boost/test/impl/unit_test_main.ipp:231
    #32 0x55917e37a1c7 in int std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>::_M_invoke<0ul, 1ul, 2ul>(std::_Index_tuple<0ul, 1ul, 2ul>) /usr/include/c++/6/functional:1400
    #33 0x55917e37a1c7 in std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>::operator()() /usr/include/c++/6/functional:1389
    #34 0x55917e37a1c7 in std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<int>, std::__future_base::_Result_base::_Deleter>, std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int>::operator()() const /usr/include/c++/6/future:1325
    #35 0x55917e37a1c7 in std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> (), std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<int>, std::__future_base::_Result_base::_Deleter>, std::_Bind_simple<int (*(boost::unit_test::test_suite* (*)(int, char**), int, char**))(boost::unit_test::test_suite* (*)(int, char**), int, char**)>, int> >::_M_invoke(std::_Any_data const&) /usr/include/c++/6/functional:1726
    #36 0x55917e38458b in std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>::operator()() const /usr/include/c++/6/functional:2136
    #37 0x55917e384646 in std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*) /usr/include/c++/6/future:533
    #38 0x55917e377b87 in void std::__invoke_impl<void, void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::__invoke_memfun_deref, void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) /usr/include/c++/6/functional:235
    #39 0x55917e377b87 in std::result_of<void (std::__future_base::_State_baseV2::* const&(std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&))(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>::type std::__invoke<void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(void (std::__future_base::_State_baseV2::* const&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) /usr/include/c++/6/functional:260
    #40 0x55917e377b87 in decltype (__invoke((*this)._M_pmf, (forward<std::__future_base::_State_baseV2*>)({parm#1}), (forward<std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*>)({parm#1}), (forward<bool*>)({parm#1}))) std::_Mem_fn_base<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), true>::operator()<std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) const /usr/include/c++/6/functional:613
    #41 0x55917e377b87 in void std::_Bind_simple<std::_Mem_fn<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> (std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>::_M_invoke<0ul, 1ul, 2ul>(std::_Index_tuple<0ul, 1ul, 2ul>) /usr/include/c++/6/functional:1400
    #42 0x55917e377b87 in std::_Bind_simple<std::_Mem_fn<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> (std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>::operator()() /usr/include/c++/6/functional:1389
    #43 0x55917e377b87 in void std::__once_call_impl<std::_Bind_simple<std::_Mem_fn<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> (std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)> >() /usr/include/c++/6/mutex:587
    #44 0x7f278d36ac18 in __pthread_once_slow (/lib/x86_64-linux-gnu/libpthread.so.0+0xec18)

Thread T1 created by T0 here:
    #0 0x7f278d5ab4e8 in __interceptor_pthread_create (/usr/lib/x86_64-linux-gnu/libasan.so.3+0x314e8)
    #1 0x7f278ca17824 in std::thread::_M_start_thread(std::unique_ptr<std::thread::_State, std::default_delete<std::thread::_State> >, void (*)()) (/usr/lib/x86_64-linux-gnu/libstdc++.so.6+0xbb824)
    #2 0x55917e377260 in std::future<std::result_of<std::decay<int (&)(boost::unit_test::test_suite* (*)(int, char**), int, char**)>::type (std::decay<boost::unit_test::test_suite* (&)(int, char**)>::type, std::decay<int&>::type, std::decay<char**&>::type)>::type> std::async<int (&)(boost::unit_test::test_suite* (*)(int, char**), int, char**), boost::unit_test::test_suite* (&)(int, char**), int&, char**&>(int (&)(boost::unit_test::test_suite* (*)(int, char**), int, char**), boost::unit_test::test_suite* (&)(int, char**), int&, char**&) /usr/include/c++/6/future:1743
    #3 0x55917e377260 in main /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/boostTest.cpp:157
    #4 0x7f278c0953f0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x203f0)

SUMMARY: AddressSanitizer: heap-buffer-overflow /home/chfast/Projects/ethereum/cpp-ethereum/test/tools/libtesteth/ImportTest.cpp:579 in dev::test::ImportTest::exportTest(std::vector<unsigned char, std::allocator<unsigned char> > const&)
Shadow bytes around the buggy address:
  0x0c0480013590: fa fa fd fd fa fa fd fd fa fa fd fd fa fa fd fa
  0x0c04800135a0: fa fa fd fd fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c04800135b0: fa fa fd fd fa fa fd fd fa fa fd fd fa fa fd fd
  0x0c04800135c0: fa fa fd fd fa fa fd fa fa fa fd fa fa fa fd fd
  0x0c04800135d0: fa fa fd fd fa fa fd fd fa fa fd fa fa fa fd fa
=>0x0c04800135e0: fa fa fd fa fa fa fd fa fa fa 00[fa]fa fa fd fa
  0x0c04800135f0: fa fa fd fa fa fa fd fd fa fa fd fd fa fa fd fd
  0x0c0480013600: fa fa fd fa fa fa fd fa fa fa fd fd fa fa fd fa
  0x0c0480013610: fa fa fd fa fa fa fd fa fa fa fd fd fa fa fd fa
  0x0c0480013620: fa fa fd fd fa fa fd fa fa fa fd fa fa fa fd fa
  0x0c0480013630: fa fa fd fd fa fa fd fd fa fa fd fa fa fa fd fa
Shadow byte legend (one shadow byte represents 8 application bytes):
  Addressable:           00
  Partially addressable: 01 02 03 04 05 06 07 
  Heap left redzone:       fa
  Heap right redzone:      fb
  Freed heap region:       fd
  Stack left redzone:      f1
  Stack mid redzone:       f2
  Stack right redzone:     f3
  Stack partial redzone:   f4
  Stack after return:      f5
  Stack use after scope:   f8
  Global redzone:          f9
  Global init order:       f6
  Poisoned by user:        f7
  Container overflow:      fc
  Array cookie:            ac
  Intra object redzone:    bb
  ASan internal:           fe
  Left alloca redzone:     ca
  Right alloca redzone:    cb
==13617==ABORTING
winsvega commented 7 years ago

could you tell what was in the log just before the ================================================================= line ?