Bug 281685 - ASAN intercepting SHA256 and MD5 causes issues with OpenSSL's EVP
Summary: ASAN intercepting SHA256 and MD5 causes issues with OpenSSL's EVP
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: misc (show other bugs)
Version: 15.0-CURRENT
Hardware: Any Any
: --- Affects Some People
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-24 14:30 UTC by Theo Buehler
Modified: 2024-09-27 07:41 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Theo Buehler 2024-09-24 14:30:02 UTC
libmd has a few Init/Update/Final implementations of the same name as OpenSSL but with incompatible signature. For FreeBSD this is at least SHA2 and MD5. This causes issues when using ASAN, in particular in combination with EVP.

See https://github.com/libressl/portable/issues/1098 and https://github.com/openssl/openssl/issues/25456 for an example.

I suspect defining `SANITIZER_INTERCEPT_*` for these needs to be reconsidered.
Comment 1 Theo Buehler 2024-09-27 07:41:11 UTC
I reported this to LLVM upstream to make the NetBSD developers who added this aware.

https://github.com/llvm/llvm-project/issues/110215