test-crypto.c - Assert failed

Tamsy dovecot-list at mohtex.net
Wed Jul 27 04:31:37 UTC 2022


Dear List,

Please pardon me if this has been already discussed before. I couldn't 
find the matter with a quick search.

On a new standard Ubuntu 22.04 LTS installation Dovecot's "configure && 
make" runs through but "make check" fails.

Is dovecot-2.3.19.1 not yet compatible with openSSL 3.0.2 (openssl 
3.0.2-0ubuntu1.6) or is this just happening here?


Distributor ID: Ubuntu
Description:    Ubuntu 22.04 LTS
Release:        22.04
Codename:       jammy

Linux 5.15.0-41-generic #44-Ubuntu SMP Wed Jun 22 14:20:53 UTC 2022 
x86_64 x86_64 x86_64 GNU/Linux


$ make check

<SNIP>
test_cipher_test_vectors ............................................. : ok
test_cipher_aead_test_vectors ........................................ : ok
test_hmac_test_vectors ............................................... : ok
test_load_v1_keys .................................................... : ok
test_load_v1_key ..................................................... : ok
test_load_v1_public_key .............................................. : ok
test_load_v2_key ..................................................... : ok
test_load_v2_public_key .............................................. : ok
test_get_info_v2_key ................................................. : ok
test_gen_and_get_info_rsa_pem ........................................ : ok
test_get_info_rsa_private_key ........................................ : ok
test_get_info_invalid_keys ........................................... : ok
test_get_info_key_encrypted .......................................... : ok
test_get_info_pw_encrypted ........................................... : ok
test-crypto.c:827: Assert failed: ret == TRUE
Panic: file dcrypt-openssl.c: line 2639 
(dcrypt_openssl_private_to_public_key): assertion failed: (priv_key != 
NULL && pub_key_r != NULL)
Error: Raw backtrace: ./test-crypto(+0x60704) [0x168704] -> 
./test-crypto(backtrace_append+0x1c) [0x168893] -> 
./test-crypto(backtrace_get+0x2a) [0x1688bf] -> ./test-crypto(+0x28ef4) 
[0x130ef4] -> ./test-crypto(default_fatal_handler+0) [0x130fc6] -> 
./test-crypto(default_error_handler+0) [0x131014] -> 
./test-crypto(i_fatal+0) [0x1312ae] -> 
.libs/libdcrypt_openssl.so(+0xe795) [0x4ea3795] -> 
./test-crypto(dcrypt_key_convert_private_to_public+0x7b) [0x11eeb1] -> 
./test-crypto(+0x21655) [0x129655] -> ./test-crypto(+0x23d66) [0x12bd66] 
-> ./test-crypto(test_run+0x21) [0x12c13a] -> ./test-crypto(main+0x83) 
[0x12af16] -> /lib/x86_64-linux-gnu/libc.so.6(+0x29d90) [0x4893d90] -> 
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0x80) [0x4893e40] -> 
./test-crypto(_start+0x25) [0x11c1a5]
../../run-test.sh: line 39: 164971 Aborted                 (core dumped) 
/usr/bin/valgrind -q $trace_children --error-exitcode=213 
--leak-check=full --gen-suppressions=all --suppressions="$supp_path" 
--log-file=$test_out $noundef $*
==164971== Conditional jump or move depends on uninitialised value(s)
==164971==    at 0x514E234: ??? (in 
/usr/lib/x86_64-linux-gnu/libcrypto.so.3)
==164971==    by 0x514E511: ??? (in 
/usr/lib/x86_64-linux-gnu/libcrypto.so.3)
==164971==    by 0x504F0F4: EVP_DecryptFinal_ex (in 
/usr/lib/x86_64-linux-gnu/libcrypto.so.3)
==164971==    by 0x4E9CD3F: dcrypt_openssl_ctx_sym_final (in 
/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt/.libs/libdcrypt_openssl.so)
==164971==    by 0x11E3DB: dcrypt_ctx_sym_final (in 
/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt/test-crypto)
==164971==    by 0x1270DE: test_cipher_aead_test_vectors (in 
/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt/test-crypto)
==164971==    by 0x12BD65: test_run_funcs (in 
/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt/test-crypto)
==164971==    by 0x12C139: test_run (in 
/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt/test-crypto)
==164971==    by 0x12AF15: main (in 
/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt/test-crypto)
==164971==
{
    <insert_a_suppression_name_here>
    Memcheck:Cond
    obj:/usr/lib/x86_64-linux-gnu/libcrypto.so.3
    obj:/usr/lib/x86_64-linux-gnu/libcrypto.so.3
    fun:EVP_DecryptFinal_ex
    fun:dcrypt_openssl_ctx_sym_final
    fun:dcrypt_ctx_sym_final
    fun:test_cipher_aead_test_vectors
    fun:test_run_funcs
    fun:test_run
    fun:main
}
==164971== 2,304 bytes in 1 blocks are possibly lost in loss record 911 
of 947
==164971==    at 0x4848899: malloc (in 
/usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so)
==164971==    by 0x4005D97: malloc (rtld-malloc.h:56)
==164971==    by 0x4005D97: _dlfo_mappings_segment_allocate 
(dl-find_object.c:217)
==164971==    by 0x4005D97: _dl_find_object_update_1 (dl-find_object.c:671)
==164971==    by 0x4005D97: _dl_find_object_update (dl-find_object.c:804)
==164971==    by 0x400ECCF: dl_open_worker_begin (dl-open.c:735)
==164971==    by 0x49DEC27: _dl_catch_exception (dl-error-skeleton.c:208)
==164971==    by 0x400DF99: dl_open_worker (dl-open.c:782)
==164971==    by 0x49DEC27: _dl_catch_exception (dl-error-skeleton.c:208)
==164971==    by 0x400E34D: _dl_open (dl-open.c:883)
==164971==    by 0x48FA6BB: dlopen_doit (dlopen.c:56)
==164971==    by 0x49DEC27: _dl_catch_exception (dl-error-skeleton.c:208)
==164971==    by 0x49DECF2: _dl_catch_error (dl-error-skeleton.c:227)
==164971==    by 0x48FA1AD: _dlerror_run (dlerror.c:138)
==164971==    by 0x48FA747: dlopen_implementation (dlopen.c:71)
==164971==    by 0x48FA747: dlopen@@GLIBC_2.34 (dlopen.c:81)
==164971==
{
    <insert_a_suppression_name_here>
    Memcheck:Leak
    match-leak-kinds: possible
    fun:malloc
    fun:malloc
    fun:_dlfo_mappings_segment_allocate
    fun:_dl_find_object_update_1
    fun:_dl_find_object_update
    fun:dl_open_worker_begin
    fun:_dl_catch_exception
    fun:dl_open_worker
    fun:_dl_catch_exception
    fun:_dl_open
    fun:dlopen_doit
    fun:_dl_catch_exception
    fun:_dl_catch_error
    fun:_dlerror_run
    fun:dlopen_implementation
    fun:dlopen@@GLIBC_2.34
}
==164971== 2,304 bytes in 1 blocks are possibly lost in loss record 912 
of 947
==164971==    at 0x4848899: malloc (in 
/usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so)
==164971==    by 0x4005D97: malloc (rtld-malloc.h:56)
==164971==    by 0x4005D97: _dlfo_mappings_segment_allocate 
(dl-find_object.c:217)
==164971==    by 0x4005D97: _dl_find_object_update_1 (dl-find_object.c:671)
==164971==    by 0x4005D97: _dl_find_object_update (dl-find_object.c:804)
==164971==    by 0x400ECCF: dl_open_worker_begin (dl-open.c:735)
==164971==    by 0x49DEC27: _dl_catch_exception (dl-error-skeleton.c:208)
==164971==    by 0x400DF99: dl_open_worker (dl-open.c:782)
==164971==    by 0x49DEC27: _dl_catch_exception (dl-error-skeleton.c:208)
==164971==    by 0x400E34D: _dl_open (dl-open.c:883)
==164971==    by 0x49DEF90: do_dlopen (dl-libc.c:95)
==164971==    by 0x49DEC27: _dl_catch_exception (dl-error-skeleton.c:208)
==164971==    by 0x49DECF2: _dl_catch_error (dl-error-skeleton.c:227)
==164971==    by 0x49DF0C6: dlerror_run (dl-libc.c:45)
==164971==    by 0x49DF0C6: __libc_dlopen_mode (dl-libc.c:162)
==164971==    by 0x498F7C0: __libc_unwind_link_get (unwind-link.c:50)
==164971==    by 0x498F7C0: __libc_unwind_link_get (unwind-link.c:40)
==164971==
{
    <insert_a_suppression_name_here>
    Memcheck:Leak
    match-leak-kinds: possible
    fun:malloc
    fun:malloc
    fun:_dlfo_mappings_segment_allocate
    fun:_dl_find_object_update_1
    fun:_dl_find_object_update
    fun:dl_open_worker_begin
    fun:_dl_catch_exception
    fun:dl_open_worker
    fun:_dl_catch_exception
    fun:_dl_open
    fun:do_dlopen
    fun:_dl_catch_exception
    fun:_dl_catch_error
    fun:dlerror_run
    fun:__libc_dlopen_mode
    fun:__libc_unwind_link_get
    fun:__libc_unwind_link_get
}
Failed to run: ./test-crypto
make[3]: *** [Makefile:1136: check-local] Error 1
make[3]: Leaving directory '/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt'
make[2]: *** [Makefile:983: check-am] Error 2
make[2]: Leaving directory '/usr/local/src/dovecot-2.3.19.1/src/lib-dcrypt'
make[1]: *** [Makefile:573: check-recursive] Error 1
make[1]: Leaving directory '/usr/local/src/dovecot-2.3.19.1/src'
make: *** [Makefile:702: check-recursive] Error 1
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_0xDD9B7A9E789E5A4F.asc
Type: application/pgp-keys
Size: 648 bytes
Desc: OpenPGP public key
URL: <https://dovecot.org/pipermail/dovecot/attachments/20220727/3d949ab9/attachment.key>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 236 bytes
Desc: OpenPGP digital signature
URL: <https://dovecot.org/pipermail/dovecot/attachments/20220727/3d949ab9/attachment.sig>


More information about the dovecot mailing list