Unable to load crypto library. Failed with error:

Home Forums Basic Erlang Unable to load crypto library. Failed with error:

This topic contains 4 replies, has 3 voices, and was last updated by  Dawn T Cherian 4 months ago.

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #37025

    A problem with the Mac installer of Erlang/OTP has been found.

    The Erlang package on Mac OS X 10.9.3, and there seems to be a problem with the crypto library:

    $ erl
    Erlang/OTP 17 [erts-6.0] [source-07b8f44] [64-bit] [smp:8:8] [async-threads:10] [hipe] [kernel-poll:false] [dtrace]

    Eshell V6.0 (abort with ^G)
    1> l(crypto).
    {error,on_load_failure}

    =ERROR REPORT==== 9-Jun-2014::15:57:46 ===
    Unable to load crypto library. Failed with error:
    “load_failed, Failed to load NIF library: ‘dlopen(/usr/local/lib/erlang/lib/crypto-3.3/priv/lib/crypto.so, 2): Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib
    Referenced from: /usr/local/lib/erlang/lib/crypto-3.3/priv/lib/crypto.so
    Reason: image not found’”
    OpenSSL might not be installed on this system.

    =ERROR REPORT==== 9-Jun-2014::15:57:46 ===
    The on_load function for module crypto returned {error,
    {load_failed,
    “Failed to load NIF library: ‘dlopen(/usr/local/lib/erlang/lib/crypto-3.3/priv/lib/crypto.so, 2): Library not loaded: /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib\n Referenced from: /usr/local/lib/erlang/lib/crypto-3.3/priv/lib/crypto.so\n Reason: image not found’”}}

    #37187

    I am looking into this issue at the moment.

    #38844

    The crypto library should work properly now.

    #49180

    Hi,
    I am using a Bcrypt library (http://sigma-star.com/blog/post/proper-password-hashing-in-erlang-with) for hashing purpose. I successfully added it in a project and everything was perfect. But I had to clone the project(without hashing fn) again and redo the same work. But this time am getting this error.

    {error_logger,{{2015,1,15},{19,47,28}},crash_report,[[{initial_call,{application_master,init,['Argument__1','Argument__2','Argument__3','Argument__4']}},{pid,<0.901.0>},{registered_name,[]},{error_info,{exit,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,bcrypt_nif}}},{kernel,start,[normal,[]]}},[{application_master,init,4,[{file,"application_master.erl"},{line,133}]},{proc_lib,init_p_do_apply,3,[{file,"proc_lib.erl"},{line,237}]}]}},{ancestors,[<0.900.0>]},{messages,[{'EXIT',<0.902.0>,normal}]},{links,[<0.900.0>,<0.899.0>]},{dictionary,[]},{trap_exit,true},{status,running},{heap_size,376},{stack_size,27},{reductions,117}],[]]}
    {error_logger,{{2015,1,15},{19,47,28}},std_info,[{application,kernel},{exited,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,bcrypt_nif}}},{kernel,start,[normal,[]]}}},{type,permanent}]}
    {“Kernel pid terminated”,application_controller,”{application_start_failure,kernel,{{shutdown,{failed_to_start_child,kernel_safe_sup,{on_load_function_failed,bcrypt_nif}}},{kernel,start,[normal,[]]}}}”}

    #49606

    Added {so_name, “bcrypt_nif.so”} in rebar.config of bcrypt and it worked.

Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.