This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-crypto.git


The following commit(s) were added to refs/heads/master by this push:
     new 62e00af6 Document macOS issues [skip ci]
62e00af6 is described below

commit 62e00af62e22f1b5f5e5d2b1f7992599373962e9
Author: Sebb <[email protected]>
AuthorDate: Fri Nov 24 14:02:59 2023 +0000

    Document macOS issues [skip ci]
---
 LIBRARY_NAMES.txt | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/LIBRARY_NAMES.txt b/LIBRARY_NAMES.txt
index 437acce9..192f9f7c 100644
--- a/LIBRARY_NAMES.txt
+++ b/LIBRARY_NAMES.txt
@@ -42,4 +42,16 @@ Windows:
 
 > mvn ... -D"commons.crypto.OpenSslNativeJni=libcrypto-1_1-x64" 
 > -D"commons.crypto.OpenSslNativeJna=libcrypto-1_1-x64" ...
 
+Library override is needed on macOS
+-----------------------------------
+Attempts to load the default library on macOS cause the application to crash 
with a message of the form:
+'".../bin/java is loading libcrypto in an unsafe way"
 
+To fix this, he properties jni.library.path and/or jna.library.path need to be 
set to the appropriate path,
+for example /usr/local/lib.
+
+An alternative is to ensure that there is a copy of the library in the 
application launch directory.
+This can be a soft link to the actual library. This only works for 
unrestricted processes.
+
+It does not appear to be possible to use any of the DYLIB_ environment 
variables.
+These are removed as part of System Integrity Protection, so are not seen by 
the application and dlopen().

Reply via email to