开发者

Problem with ilasm

开发者 https://www.devze.com 2022-12-17 14:07 出处:网络
I have a quite big program in .net 3.5 SP1 which is compiling just fine. However when I want to obfuscate it with Obfuscator Pro (evaluation for now), Obfuscator stops with the following error:

I have a quite big program in .net 3.5 SP1 which is compiling just fine. However when I want to obfuscate it with Obfuscator Pro (evaluation for now), Obfuscator stops with the following error:

[Build Output] This application has requested the Runtime to terminate it in an unusual way.

[Build Output] Please contact the application's support team for more information.

[Build Output] ilasm returned 3

[Build Output] Build Error.

Since the error comes from ILASM, I thought lets do what Obfuscator does (w/o obfuscation) and executed the following commands:

=> ildasm.exe /OUT=C:\MyApp.exe.il /TEXT /NOBAR /RAWEH /QUOTEALLNAMES /UTF8 /LINENUM /FORWARD C:\MyApp\bin\Release\MyApp.exe

=> ilasm C:\MyApp.exe.il

The first command (ILDASM) passes just fine, I get a 450MB IL file.

The second command (ILASM) however crashes with the following error:

This application has requested the Runtime to terminate it in an unusual way.

Please contact the application's support team for more information.

Does anybody have any idea what the error could be?

My system is Windows 7 x64 with the tools from Visual Studio 2008 (SP1).

UPDATE:

I contacted Obfuscator support and did some tests for them. They have really helpful people there by the way.

We've discovered that the error happens only when using the x86 ILASM from the .net 2.0 framework folder. When using the one from the framework64\v2.0... then the error doesn't happen.

Also when using either (x86 or x64) ILASM from .net 4.0 (Beta 2) it passes just fine.

So this really looks like a bug in the ILASM o开发者_Python百科f .net 2.0 for x86.


While the issue with ILASM isn't really solved, the following fixed the problem:

  • Use ILASM from framework64 folder
    The x64 ILASM works fine. However I couldn't force Dotfuscator to use it.
  • Install .net framework 4.0 (Beta 2)
    When ILASM from .net framework 4.0 is used it works just fine.
  • Run Dotfuscator with the '/inpl:on' flag
    Dotfuscator support told me to use this flag and it worked fine.
    According to them there shouldn't be any difference in the generated EXE so I'm using this solution currently (The flag is not available in the GUI).
0

精彩评论

暂无评论...
验证码 换一张
取 消