lachesis / scallion

GPU-based Onion Hash generator

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

OpenSSL System.EntryPointNotFoundException: ERR_load_crypto_strings

kintarowonders opened this issue · comments

I run Fedora 26 Workstation as my operating system. It seems the update from Fedora 25 has broken Scallion which has worked for years. The issue seems to be the latest OpenSSL. Perhaps Scallion needs to be updated because I can't seem to fix this any other way. I had to build Scallion with target framework 4.5, using the latest OpenSSL .NET from github. This might be related but I couldn't get Scallion to build any other way.

$ mono scallion.exe -n

Unhandled Exception:
System.TypeInitializationException: The type initializer for 'OpenSSL.Core.Native' threw an exception. ---> System.EntryPointNotFoundException: ERR_load_crypto_strings
  at (wrapper managed-to-native) OpenSSL.Core.Native:ERR_load_crypto_strings ()
  at OpenSSL.Core.Native..cctor () [0x000ce] in <fbcc6a5f85ac41afab1d0ed9983f141e>:0 
   --- End of inner exception stack trace ---
  at OpenSSL.Core.ThreadInitialization.InitializeThreads () [0x00001] in <fbcc6a5f85ac41afab1d0ed9983f141e>:0 
  at scallion.Program.Main (System.String[] args) [0x00007] in <f9d0c85c1ccc441dbe7ced1254d1a450>:0 
[ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: The type initializer for 'OpenSSL.Core.Native' threw an exception. ---> System.EntryPointNotFoundException: ERR_load_crypto_strings
  at (wrapper managed-to-native) OpenSSL.Core.Native:ERR_load_crypto_strings ()
  at OpenSSL.Core.Native..cctor () [0x000ce] in <fbcc6a5f85ac41afab1d0ed9983f141e>:0 
   --- End of inner exception stack trace ---
  at OpenSSL.Core.ThreadInitialization.InitializeThreads () [0x00001] in <fbcc6a5f85ac41afab1d0ed9983f141e>:0 
  at scallion.Program.Main (System.String[] args) [0x00007] in <f9d0c85c1ccc441dbe7ced1254d1a450>:0

Same with archlinux (compiling from git):

[root@hexodica scallion]# mono --runtime=v4.0.30319 scallion/bin/Debug/scallion.exe -d 0 prefix

Unhandled Exception:
System.TypeInitializationException: The type initializer for 'OpenSSL.Core.Native' threw an exception. ---> System.EntryPointNotFoundException: ERR_load_crypto_strings
  at (wrapper managed-to-native) OpenSSL.Core.Native:ERR_load_crypto_strings ()
  at OpenSSL.Core.Native..cctor () [0x0007a] in <149e32038c88493fadc1a0a7886a9f9f>:0 
   --- End of inner exception stack trace ---
  at OpenSSL.Core.ThreadInitialization.InitializeThreads () [0x00001] in <149e32038c88493fadc1a0a7886a9f9f>:0 
  at scallion.Program.Main (System.String[] args) [0x00007] in <111a8cab284347f0afe55b03f8ea107d>:0 
[ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: The type initializer for 'OpenSSL.Core.Native' threw an exception. ---> System.EntryPointNotFoundException: ERR_load_crypto_strings
  at (wrapper managed-to-native) OpenSSL.Core.Native:ERR_load_crypto_strings ()
  at OpenSSL.Core.Native..cctor () [0x0007a] in <149e32038c88493fadc1a0a7886a9f9f>:0 
   --- End of inner exception stack trace ---
  at OpenSSL.Core.ThreadInitialization.InitializeThreads () [0x00001] in <149e32038c88493fadc1a0a7886a9f9f>:0 
  at scallion.Program.Main (System.String[] args) [0x00007] in <111a8cab284347f0afe55b03f8ea107d>:0 

Same with Debian stretch and Intel opencl (beignet-opencl-icd)
Build command:

xbuild scallion.sln /p:TargetFrameworkVersion="v4.5"

Error:

Unhandled Exception:
System.TypeInitializationException: The type initializer for 'OpenSSL.Core.Native' threw an exception. ---> System.EntryPointNotFoundException: ERR_load_crypto_strings
  at (wrapper managed-to-native) OpenSSL.Core.Native:ERR_load_crypto_strings ()
  at OpenSSL.Core.Native..cctor () [0x000ce] in <b3b494d56415444dbfd93591999af0e6>:0 
   --- End of inner exception stack trace ---
  at OpenSSL.Core.ThreadInitialization.InitializeThreads () [0x00001] in <b3b494d56415444dbfd93591999af0e6>:0 
  at scallion.Program.Main (System.String[] args) [0x00007] in <effdca300c264dc1a5a1b0a26ea83b0d>:0 
[ERROR] FATAL UNHANDLED EXCEPTION: System.TypeInitializationException: The type initializer for 'OpenSSL.Core.Native' threw an exception. ---> System.EntryPointNotFoundException: ERR_load_crypto_strings
  at (wrapper managed-to-native) OpenSSL.Core.Native:ERR_load_crypto_strings ()
  at OpenSSL.Core.Native..cctor () [0x000ce] in <b3b494d56415444dbfd93591999af0e6>:0 
   --- End of inner exception stack trace ---
  at OpenSSL.Core.ThreadInitialization.InitializeThreads () [0x00001] in <b3b494d56415444dbfd93591999af0e6>:0 
  at scallion.Program.Main (System.String[] args) [0x00007] in <effdca300c264dc1a5a1b0a26ea83b0d>:0`

Removing libssl-dev and installing libssl1.0-dev solved the issue for me.

@ccmawo Thanks! I am also getting slimier issue. It works!

I'm not familiar with C# or xbuild. How do I use my own OpenSSL build in /usr/local with this project?

Fixed with:

dnf install compat-openssl10-devel

Just a note that as of Debian 10 (Buster) the 1.0.x series of OpenSSL is no longer available to install via package management. I didn't find a fork of openssl-net that moved on to the 1.1 series (the 2016 version) or any issues or pull requests talking about it. OpenSSL EOL'ed 1.0.2 at the end of last year and are working on a 3.0 release now.

libssl1.0-dev is not abailable on Ubuntu 20.04

$ sudo aptitude search libssl
i libssl-dev - Secure Sockets Layer toolkit - development files
p libssl-dev:i386 - Secure Sockets Layer toolkit - development files
p libssl-doc - Secure Sockets Layer toolkit - development documentation
v libssl-doc:i386 -
p libssl-ocaml - OCaml bindings for OpenSSL (runtime)
v libssl-ocaml-1vnr6 -
p libssl-ocaml-dev - OCaml bindings for OpenSSL
v libssl-ocaml-dev-1vnr6 -
p libssl-utils-clojure - library for SSL certificate management on the JVM
i A libssl1.0.2 - Secure Sockets Layer toolkit - shared libraries
i A libssl1.1 - Secure Sockets Layer toolkit - shared libraries
p libssl1.1:i386 - Secure Sockets Layer toolkit - shared libraries