Skip to content

segmentation fault in cosmian_kms openssl::version::version #691

@serene-kitfisto-8899

Description

@serene-kitfisto-8899

Hi,

In some edge cases (missing OpenSSL, restricted env, etc. ) you try to print the OpenSSL version but the OpenSSL crate is not loaded :

In https://github.com/Cosmian/kms/tree/develop/crate/server/src/main.rs line 94 :

     #[cfg(not(feature = "non-fips"))]
    info!(
        "OpenSSL FIPS mode version: {}, in {}, number: {:x}",
        openssl::version::version(),
        openssl::version::dir(),
        openssl::version::number()
    );
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x00007ffff647565c in openssl::version::version::h488186c499d88bc3 ()
#2  0x00007ffff30113be in cosmian_kms::main::{{closure}}::h5507ab6a5673b02c ()
#3  0x00007ffff31968fe in tokio::runtime::park::CachedParkThread::block_on::{{closure}}::hb5a6eaa26b9ffa61 ()
#4  0x00007ffff3195df9 in tokio::runtime::park::CachedParkThread::block_on::h474bc5623f34d365 ()
#5  0x00007ffff3196a44 in tokio::runtime::context::blocking::BlockingRegionGuard::block_on::h21ff566355584433 ()
#6  0x00007ffff3030841 in tokio::runtime::scheduler::multi_thread::MultiThread::block_on::{{closure}}::h5e5fffb51bcd46a6 ()
#7  0x00007ffff311458b in tokio::runtime::context::runtime::enter_runtime::hf91e55d54c09d5cd ()
#8  0x00007ffff30307a2 in tokio::runtime::scheduler::multi_thread::MultiThread::block_on::h68ce1a7a14e441bd ()
#9  0x00007ffff30a9f72 in tokio::runtime::runtime::Runtime::block_on_inner::hf64a1936f7db4145 ()
#10 0x00007ffff30aa210 in tokio::runtime::runtime::Runtime::block_on::ha8ac16652addc755 ()
#11 0x00007ffff300fa72 in cosmian_kms::main::h24bdca66f6d6c17e ()
#12 0x00007ffff30168e2 in core::ops::function::FnOnce::call_once::hd96e424925dc0c58 ()
#13 0x00007ffff3061db5 in std::sys::backtrace::__rust_begin_short_backtrace::hc8fdda6cb76bb0aa ()
#14 0x00007ffff3158b76 in std::rt::lang_start::{{closure}}::h1a951db306945303 ()
#15 0x00007ffff7082c20 in std::rt::lang_start_internal::h8292af041f034f6d ()
#16 0x00007ffff3158b57 in std::rt::lang_start::hf2bd0fe5c3c6fbf8 ()
#17 0x00007ffff30139ee in main ()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions