Obfuscated .NET 4.6 assembly fails strangely on machine with .NET 4.5

I've observed some odd behaviour with an executable compiled for .NET 4.6, when trying to run it on a machine that has only .NET 4.5.2 installed.
When I try to run the un-obfuscated version of the application, it gives an error about the required .NET version not being installed, as you'd expect.
When I run the obfuscated version, it actually starts up successfully, and partly works - but then falls over with an error when it tries to use a framework function that was new in .NET 4.6.
Can anyone shed any light on why this happens? Obviously I'd prefer it if the obfuscated version behaved like the non-obfuscated version, and gave a clear error if the user doesn't have the right .NET version.
Tagged:

Comments

  • Jessica RJessica R Posts: 1,319 Rose Gold 4
    Hi @AndyL,

    Thanks for your post!

    I unfortunately wasn't able to reproduce this so far with a quick test (I didn't get the start-up error in either the original or SA-processed application). Can I just check:

    - What operating system(s) are you using SA on and then testing the exe on?
    - On the machine where you've used SA, are there any other installed .NET frameworks?
    - Would it be possible for you to share the original and protected .exe's or a cut down version that reproduces the problem? (If so, please send this to support@red-gate.com with "Files for #94205" as the subject)

    Thanks!

    Jessica Ramos | Product Support Engineer | Redgate Software

    Have you visited our Help Center?


Sign In or Register to comment.