首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >混淆C#代码与混淆者不适用于语言资源文件(DLL)

混淆C#代码与混淆者不适用于语言资源文件(DLL)
EN

Stack Overflow用户
提问于 2014-04-12 22:02:50
回答 2查看 2.3K关注 0票数 4

我在Visual 2012中有一个C#项目(WinForms),运行Windows7Professional 64位。

我的WinForms应用程序有两种语言--英语和德语。因此,在我的Visual项目中,我有两个资源文件(.resx),lang.resx (包含我的默认语言德语)和(包含我的可选语言,英语)。

当我为.NET 3.5编译我的项目时,VS在我的应用程序项目文件夹中创建两个文件夹,"de_DE"和"en_GB",并将包含语言内容的DLL文件复制到这两个文件夹中(这两个文件都称为"app.resources.dll")。

到现在为止还好。我的应用程序在没有“困惑”的情况下运行良好。在Windows的英文副本上运行时,它显示英文文本,在德语或其他任何Windows语言副本上运行时,它显示德语文本.不出所料。

现在,我将我的代码与混淆用户(在CodePlex:https://confuser.codeplex.com/上找到)混淆在一起,使用的是ConfuorVersion1.9(最新的预编译、可下载的.exe版本)。

当我向混淆者添加"app.exe“和”DE-DE\app.resources es.dll“和”en\app.Resoures.dll“时,混淆器将只生成1个混淆的app.resources.dll -而不是2(每种语言/资源DLL各一个)。

这意味着,我不能在语言之间切换,因为混淆者似乎只考虑了一个app.resources.dll (而不是两者)。

我想我的项目设置没有什么特别之处或突出之处(普通的WinForm应用程序有不止一种语言)。

我的问题是:

如何配置混淆器,使其正确地混淆我的app.exe和两个app.resources.dll文件?

任何帮助(甚至暗示)都是非常感谢的!

EN

回答 2

Stack Overflow用户

发布于 2014-04-15 12:51:05

在混淆用户补丁列表中,它解决了您的确切问题:) http://confuser.codeplex.com/sourcecontrol/list/patches

修补程序ID 14664与您的问题有关,看起来您需要在项目文件中设置条目(摘录他们自己的站点):

代码语言:javascript
复制
An example with language files, showing what the output should be:

Executables\Common.resources.dll -> targetfolder\common.resources.dll
Executables\de\Common.resources.dll -> targetfolder\de\common.resources.dll
Executables\fi\Common.resources.dll -> targetfolder\fi\common.resources.dll

etc.

After patching this can now be achieved with the following kind of project file:

...
<assembly path="..\Executables\Common.resources.dll" />
<assembly path="..\Executables\de\Common.resources.dll" toSubFolder="de" />
<assembly path="..\Executables\fi\Common.resources.dll" toSubFolder="fi" />
票数 1
EN

Stack Overflow用户

发布于 2014-04-12 23:56:11

您不能只重命名DLL吗?

  • DE-DE\app.resources es.dll => DE-DE_app.resources es.dll
  • en-GB\app.resources es.dll => en-GB_app.resources es.dll
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/23036669

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档