I have been having some difficulty getting dotnet to run on my machine,
uname -a
Linux Olympus 4.6.0-kali1-amd64 #1 SMP Debian 4.6.4-1kali1 (2016-07-21) x86_64 GNU/Linux
I have installed dotnet core through https://www.microsoft.com/net/core#linuxdebian
The commands I followed were:
sudo apt-get install curl libunwind8 gettext
curl -sSL -o dotnet.tar.gz https://go.microsoft.com/fwlink/?linkid=843453
sudo mkdir -p /opt/dotnet && sudo tar zxf dotnet.tar.gz -C /opt/dotnet
sudo ln -s /opt/dotnet/dotnet /usr/local/bin
Then using the next step of initializing the code, I get:
dotnet --info
.NET Command Line Tools (1.0.1)
Product Information:
Version: 1.0.1
Runtime Environment:
OS Name: kali
OS Version: 2016.2
OS Platform: Linux
RID: debian.8-x64
Base Path: /opt/dotnet/sdk/1.0.1
and the error I get is:
dotnet new
Unhandled Exception: System.TypeInitializationException: The type initializer for 'Crypto' threw an exception. ---> System.TypeInitializationException: The type initializer for 'CryptoInitializer' threw an exception. ---> System.DllNotFoundException: Unable to load DLL 'System.Security.Cryptography.Native.OpenSsl': The specified module could not be found.
(Exception from HRESULT: 0x8007007E)
at Interop.CryptoInitializer.EnsureOpenSslInitialized()
at Interop.CryptoInitializer..cctor()
--- End of inner exception stack trace ---
at Interop.Crypto..cctor()
--- End of inner exception stack trace ---
at Interop.Crypto.GetRandomBytes(Byte* buf, Int32 num)
at System.IO.Path.GetCryptoRandomBytesOpenSsl(Byte* bytes, Int32 byteCount)
at System.IO.Path.GetCryptoRandomBytes(Byte* bytes, Int32 byteCount)
at System.IO.Path.GetRandomFileName()
at Microsoft.DotNet.InternalAbstractions.TemporaryDirectory..ctor()
at Microsoft.Extensions.EnvironmentAbstractions.DirectoryWrapper.CreateTemporaryDirectory()
at Microsoft.DotNet.Configurer.NuGetPackagesArchiver..ctor()
at Microsoft.DotNet.Cli.Program.ConfigureDotNetForFirstTimeUse(INuGetCacheSentinel nugetCacheSentinel)
at Microsoft.DotNet.Cli.Program.ProcessArgs(String[] args, ITelemetry telemetryClient)
at Microsoft.DotNet.Cli.Program.Main(String[] args)
Aborted
I have tried to research this issue, but most of the issues come from MacOSx and are Mac-related.
I have also tried to update openssl:
openssl version
OpenSSL 1.1.0e 16 Feb 2017
I'm not quite sure what to do next. Has anyone else come across this issue or have an idea where I can go from here? I have been able to successfully use dotnet on linux mint 17, but not for kali linux.