小编Vae*_*tus的帖子

通过直接读取PE来确定dll是否是.valid CLR dll(64位问题)

我正在努力将32位Web应用程序迁移到64位,并且我的插件加载器代码存在一些问题.

在32位版本中,我们扫描所有.net dll的webapps bin目录,然后加载它们Assembly.Load以检查我们的插件属性是否存在.

我们使用公共域代码以相当漂亮的方式完成了这项工作:

/// <summary>
/// Returns true if the file specified is a real CLR type, 
/// otherwise false is returned.
/// False is also returned in the case of an exception being caught
/// </summary>
/// <param name="file">A string representing the file to check for 
/// CLR validity</param>
/// <returns>True if the file specified is a real CLR type, 
/// otherwise false is returned.
/// False is also returned in the case of an …
Run Code Online (Sandbox Code Playgroud)

c# dll 64-bit parsing portable-executable

6
推荐指数
1
解决办法
1761
查看次数

标签 统计

64-bit ×1

c# ×1

dll ×1

parsing ×1

portable-executable ×1