为什么不.NET找到OpenSSL.NET的dll? [英] Why doesn't .NET find the OpenSSL.NET dll?

查看:137
本文介绍了为什么不.NET找到OpenSSL.NET的dll?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

修改(全部问题,它是太不清楚)

EDIT (the whole question, it was too unclear)

我想使用 OpenSSL.NET

在OpenSSL.NET安装说明页面: INSTALL

The OpenSSL.NET install instructions page: INSTALL

请确保您有LIBEAY32.DLL和ssleay32.dll在当前工作   您的应用程序,或在你的PATH目录。 完成
  在你的.NET项目,添加引用ManagedOpenSsl.dll组装。 完成

Make sure you have libeay32.dll and ssleay32.dll in the current working directory of your application or in your PATH. DONE
In your .NET project, add a reference to the ManagedOpenSsl.dll assembly. DONE

我已经把 LIBEAY32.DLL ssleay32.dll 在这两个我的 斌/调试 斌/发布 目录。我也把他们的 SYSTEM32

I have put libeay32.dll and ssleay32.dll in both my bin/Debug and bin/Release directories. I have also put them in system32.

下面是我的全部code:

Here is my FULL code:

using System;

namespace ConsoleApplication1
{
	class Program
	{
		static void Main(string[] args)
		{
			try
			{
				OpenSSL.Crypto.RSA rsa = new OpenSSL.Crypto.RSA();
			}
			catch (Exception e)
			{
				Console.WriteLine(e.InnerException.Message);
			}
			Console.Read();
		}
	}
}

我收到以下错误: (无法加载DLLlibeay32')

I get the following error: (Unable to load DLL 'libeay32')

下面是进程监视器日志(要求):

Here is the Process Monitor log (upon request):

我究竟做错了什么?为什么没有找到DLL?

推荐答案

尝试OpenSSL.NET的最新版本(<一href="http://sourceforge.net/projects/openssl-net/files/openssl-net/0.4.1/openssl-net.0.4.1-win32.zip/download"相对=nofollow> 0.4.1 ),它现在应该包括prebuilt LIBEAY32.DLL和ssleay32.dll二进制文件链接到CRT静态。或者,你可以建立这些库自己或使用'官员'打造而成openssl.org。

Try the latest version of OpenSSL.NET (0.4.1) which should now include prebuilt libeay32.dll and ssleay32.dll binaries that link to the CRT statically. Alternatively, you can build these libraries yourself or use an 'official' build from openssl.org.

这篇关于为什么不.NET找到OpenSSL.NET的dll?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆