scallion icon indicating copy to clipboard operation
scallion copied to clipboard

OpenSSL System.EntryPointNotFoundException: ERR_load_crypto_strings

Open kintarowonders opened this issue 7 years ago • 8 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

kintarowonders avatar Jun 17 '17 13:06 kintarowonders

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 

exos avatar Jul 24 '17 04:07 exos

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`

ccmawo avatar Jul 26 '17 19:07 ccmawo

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

ccmawo avatar Jul 26 '17 20:07 ccmawo

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

bubundas17 avatar Apr 30 '18 07:04 bubundas17

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

kintarowonders avatar May 02 '18 02:05 kintarowonders

Fixed with:

dnf install compat-openssl10-devel

kintarowonders avatar Oct 13 '18 03:10 kintarowonders

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.

bill-mcgonigle avatar Mar 03 '20 19:03 bill-mcgonigle

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

Kaspi314 avatar Nov 04 '20 05:11 Kaspi314