使用dotPeek反编译.net程序集会给出无效的语法 [英] Decompiling .net assembly with dotPeek gives invalid syntax

查看:603
本文介绍了使用dotPeek反编译.net程序集会给出无效的语法的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在反编译.net程序集时遇到问题.当我在dotPeek中打开程序集时,有一个名为frmMain的类,其中声明了几百个变量,如下所示:

I have a problem with decompiling .net assembly. When I open the assembly in dotPeek there is class called frmMain with few hundred variables declared like this:

[SpecialName]
private static int \u0024STATIC\u0024SortByLengthAsc\u002402811241124\u0024xlen;

当我尝试将其导出以进行投影时,即使我将所有\ u0024更改为$,所有这些行也会出现错误(未定义STATIC).我在做错什么吗?

When i try to export it to project all those lines give errors (STATIC is not defined) even if I change all the \u0024 to $. Am I doing something wrong?

推荐答案

否,程序集已被混淆,以防止人们(例如您)窥视代码并可能窃取"代码.这些变量名在IL中是允许的,但在实际的C#代码中是不允许的,因此这就是失败的原因.

No, the assembly has been obfuscated to prevent people (like you) to take a peek in the code and possibly 'steal' it. Those variable names are allowed in IL, but not in actual C# code, so that is why it fails.

我知道的唯一补救方法是反向混淆工具,该工具知道混淆器如何进行混淆并试图扭转该问题.或者,您也可以手工完成,这通常会花费很多时间,这证明了混淆带来了回报.

The only remedy I know is a reverse-obfuscation tool that knows how the obfuscator obfuscates and tries to turn that around. Or you can do it by hand, which will take a lot of time usually, which proves obfuscation pays off.

这篇关于使用dotPeek反编译.net程序集会给出无效的语法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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