hello, i am reporting a bug with regards to a missing flag in MinGW targets. the bug is present in both 0.9 and 1.0 branches; it is (in our case) only leading to crashes in 1.0.
the missing flag is: OPENSSL_SYSNAME_WIN32 it is always defined for MSVC targets, but MinGW ones are forgetting to add it. this leads to the following situation: - in e_os.h:65, the evaluation: #if defined(OPENSSL_SYS_MSDOS) && !defined(OPENSSL_SYSNAME_WIN32) is satisfied, so the MS_STATIC hack for MS-DOS becomes operational. (OPENSSL_SYS_MSDOS is always defined for every Win target in e_os2.h.) - in crypto/evp/m_sigver.c in the EVP_DigestSignFinal function, MS_STATIC is then used to define a structure that will be passed to EVP_MD_CTX_copy_ex. that function then crashes in digest.c:323 because out->digest is null and can't be dereferenced. the bug has been reported on <https://bugs.launchpad.net/dcplusplus/+bug/378829>; you may find backtraces confirming the above there. adding " -DOPENSSL_SYSNAME_WIN32" to Configure:508 (mingw target) and Configure:516 (mingw64 target) solves these problems. and while these flags are being fiddled with, i also recommend the "-mno-cygwin" flags be removed since they have been deprecated for a while now (for so long that they now provoke a compiler error). Zouzou ______________________________________________________________________ OpenSSL Project http://www.openssl.org Development Mailing List [email protected] Automated List Manager [email protected]
