UMSKT icon indicating copy to clipboard operation
UMSKT copied to clipboard

[xpkey] Segmentation fault

Open nicolaasjan opened this issue 1 year ago • 5 comments

Not sure if this is related to #22.

Compilation:

cd build/ && cmake ../ && make
-- The C compiler identification is GNU 9.4.0
-- The CXX compiler identification is GNU 9.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE  
-- Found OpenSSL: /usr/lib/x86_64-linux-gnu/libcrypto.a (found version "1.1.1f")  
-- Downloading CPM.cmake to /media/ext3-data/git/UMSKT/build/cmake/CPM_0.38.1.cmake
-- CPM: Adding package [email protected] (v3.11.2)
-- Using the multi-header code from /media/ext3-data/git/UMSKT/build/_deps/nlohmann_json-src/include/
-- CPM: Adding package [email protected] (7.1.3)
-- Version: 7.1.3
-- Build type: 
-- CXX_STANDARD: 17
-- Performing Test has_std_17_flag
-- Performing Test has_std_17_flag - Success
-- Performing Test has_std_1z_flag
-- Performing Test has_std_1z_flag - Success
-- Performing Test SUPPORTS_USER_DEFINED_LITERALS
-- Performing Test SUPPORTS_USER_DEFINED_LITERALS - Success
-- Performing Test FMT_HAS_VARIANT
-- Performing Test FMT_HAS_VARIANT - Success
-- Required features: cxx_variadic_templates
-- Looking for strtod_l
-- Looking for strtod_l - not found
-- Configuring done
-- Generating done
-- Build files have been written to: /media/ext3-data/git/UMSKT/build
Scanning dependencies of target fmt
[  7%] Building CXX object _deps/fmt-build/CMakeFiles/fmt.dir/src/format.cc.o
[ 14%] Building CXX object _deps/fmt-build/CMakeFiles/fmt.dir/src/os.cc.o
[ 21%] Linking CXX static library libfmt.a
[ 21%] Built target fmt
Scanning dependencies of target BINK1998
[ 28%] Building CXX object CMakeFiles/BINK1998.dir/src/BINK1998.cpp.o
[ 35%] Linking CXX static library libBINK1998.a
[ 35%] Built target BINK1998
Scanning dependencies of target CONFID
[ 42%] Building CXX object CMakeFiles/CONFID.dir/src/confid.cpp.o
[ 50%] Linking CXX static library libCONFID.a
[ 50%] Built target CONFID
Scanning dependencies of target BINK2002
[ 57%] Building CXX object CMakeFiles/BINK2002.dir/src/BINK2002.cpp.o
[ 64%] Linking CXX static library libBINK2002.a
[ 64%] Built target BINK2002
Scanning dependencies of target xpkey
[ 71%] Building CXX object CMakeFiles/xpkey.dir/src/main.cpp.o
[ 78%] Building CXX object CMakeFiles/xpkey.dir/src/key.cpp.o
[ 85%] Building CXX object CMakeFiles/xpkey.dir/src/util.cpp.o
[ 92%] Building CXX object CMakeFiles/xpkey.dir/src/cli.cpp.o
[100%] Linking CXX executable xpkey
/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libcrypto.a(dso_dlfcn.o): in function `dlfcn_globallookup':
(.text+0x17): warning: Using 'dlopen' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libcrypto.a(b_addr.o): in function `BIO_lookup_ex':
(.text+0xd02): warning: Using 'getaddrinfo' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libcrypto.a(b_sock.o): in function `BIO_gethostbyname':
(.text+0x75): warning: Using 'gethostbyname' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking
[100%] Built target xpkey

Running ./xpkey:

Segmentatiefout (geheugendump gemaakt)

CMakeError.log

From kern.log:

Jun 18 06:10:56 nico-desktop kernel: [ 3664.900106] xpkey[13100]: segfault at 0 ip 0000000000000000 sp 00007ffee0d5e818 error 14 in xpkey[400000+1000]
Jun 18 06:10:56 nico-desktop kernel: [ 3664.900115] Code: Bad RIP value.
Jun 18 06:16:16 nico-desktop kernel: [ 3984.949079] xpkey[13901]: segfault at 0 ip 0000000000000000 sp 00007fffc2e62678 error 14 in xpkey[400000+1000]
Jun 18 06:16:16 nico-desktop kernel: [ 3984.949088] Code: Bad RIP value.

nicolaasjan avatar Jun 18 '23 05:06 nicolaasjan