How to get .NET Reactor to produce 64-bit assemblies

345 views
Skip to first unread message

nirvana

unread,
Sep 21, 2010, 9:57:24 PM9/21/10
to .Net Reactor Support
.Net Reactor claims to support both 32-bit and 64-bit Assemblies.
However, all our 64-bit assemblies are getting converted to 32-bit
after running the .Net Reactor on them. It looks like I am not the
only person experiencing this issue, take a look at this:
http://stackoverflow.com/questions/2404469/net-reactor-how-to-protect-64-bit-assemblies

Any idea if there's something we are doing wrong or if the latest
release (v4.3.1.0) has fixed this issue (haven't tried this release
yet)?

Glen Harvy

unread,
Sep 22, 2010, 12:12:19 AM9/22/10
to net-react...@googlegroups.com
How anyone can provide help when you supply no info at all is beyond me.
How about sharing your config options for starters..

For what it's worth, my x64 project is protected by .Net Reactor
4.2.7.25 just fine.

Have you submitted a support request?

Denis

unread,
Sep 23, 2010, 12:02:38 AM9/23/10
to .Net Reactor Support
Hi Harvy,

Could it be possible that you use the "Native EXE File" option on
your assemblies? In this case the resulting assembly is always a 32
bit one.

In case you protect a x64 assembly the resulting assembly behaves as a
"AnyCPU" compiled one. This means on a x64 system it runs as x64
assembly.

Greetings,

Denis

On 22 Sep., 06:12, Glen Harvy <glenha...@gmail.com> wrote:
> How anyone can provide help when you supply no info at all is beyond me.
> How about sharing your config options for starters..
>
> For what it's worth, my x64 project is protected by .Net Reactor
> 4.2.7.25 just fine.
>
> Have you submitted a support request?
>
> On 22/09/2010 11:57 AM, nirvana wrote:
>
> > .Net Reactor claims to support both 32-bit and 64-bit Assemblies.
> > However, all our 64-bit assemblies are getting converted to 32-bit
> > after running the .Net Reactor on them.  It looks like I am not the
> > only person experiencing this issue, take a look at this:
> >http://stackoverflow.com/questions/2404469/net-reactor-how-to-protect...

Glen Harvy

unread,
Sep 23, 2010, 1:36:37 AM9/23/10
to net-react...@googlegroups.com
Hi Denis,

I trust the original poster gets this message because I don't have any
problems with this issue at all :-)

Warm regards,

Glen Harvy.

nirvana

unread,
Sep 23, 2010, 1:45:07 AM9/23/10
to .Net Reactor Support
Hi Dennis,

Thanks for your response. That exactly answers the issue and agrees
with my finding, which is .Net Reactor generates "Any CPU" assemblies
when 64 bit assemblies are protected. Like the post below, I'd expect
it to produce 64 bit assemblies from 64 bit ones and Any CPU from Any
CPU assemblies:
http://groups.google.com/group/net-reactor-support/browse_thread/thread/5f909f529ae1dd26/c46b93da25a6a708#c46b93da25a6a708

I used a tool named "inspinst.exe" to check the bitness of the
assemblies. This tool can be downloaded from "http://www.silurian.com/
win32/inspect.htm".

Regards.

nirvana

unread,
Sep 22, 2010, 10:32:14 PM9/22/10
to .Net Reactor Support
Thanks Glen for responding and sorry for not providing the required
info. Yes, we used the same release v4.2.7.5 but .Net Reactor
converted our x64 assemblies to "any CPU" assemblies (these are
neither 32 bit nor 64 bit). We used a tool called "InspectExe" to
verify that (can be downloaded from "http://www.silurian.com/win32/
inspect.htm").

Looks like other people also experiencing the issue:
- http://groups.google.com/group/net-reactor-support/browse_thread/thread/5f909f529ae1dd26/c46b93da25a6a708#c46b93da25a6a708
- http://stackoverflow.com/questions/2404469/net-reactor-how-to-protect-64-bit-assemblies

Like 'ColinA' (in the 1st post) I'd also expect this if the original
assemblies were generated as 'Any CPU' and not for x64 assemblies.

No, I have not emailed to the support on this issue yet as my previous
emails remains unanswered. Just wondering if anyone tried the latest
release v4.3.1.0 on this issue yet(?).

Glen Harvy

unread,
Sep 23, 2010, 6:09:37 PM9/23/10
to net-react...@googlegroups.com
So you are saying that you have generated an assembly that is
intentionally intended to work only on 64 bit platforms and you have
discovered that .Net Reactor is not respecting that intention?

I have no idea if .Net Reactor is capable of doing that so if it's not
claimed to be able to do that on their web site then you had better
contact support.

I'm not really interested in the other links as no one I know of posts
messages to forums saying 'it works' - you will only ever read about 'it
doesn't work' :-)

By the way, my assembly compiled with AnyCPU and protected by .Net
Reactor properly installs on a x64 bit machine (and runs in 64 bit mode)
as well as on a 32bit machine (and runs in 32 bit mode) without any
problems. In fact I don't specify anything in relation to x64 or x32
when it comes to configuring .Net Reactor - it just works :-)

There are many developers out there that have not yet discovered how
simple it is to achieve this and get all confused with Wow mode which
really has nothing to do with compiling your program.

Denis

unread,
Sep 23, 2010, 10:40:57 AM9/23/10
to .Net Reactor Support
Hi Nirvana,

I am wondering why do you have problems using the generated AnyCPU
assembly on a x64 OS. On a x64 OS the AnyCPU generated assembly
behaves exactly like a directly compiled x64 assembly. In contast to
x64 an AnyCPU assembly is not only restricted to x64 OS. BTW, the
difference between a x86 and AnyCPU compiles assembly is only one bit
which tells the runtime in which context the assembly should be
loaded. No matter if you compile your assembly as x86, x64 or AnyCPU
the method IL code remains the same.

Greetings

Denis


On 23 Sep., 07:45, nirvana <suman.das...@gmail.com> wrote:
> Hi Dennis,
>
> Thanks for your response.  That exactly answers the issue and agrees
> with my finding, which is .Net Reactor generates "Any CPU" assemblies
> when 64 bit assemblies are protected.  Like the post below, I'd expect
> it to produce 64 bit assemblies from 64 bit ones and Any CPU from Any
> CPU assemblies:http://groups.google.com/group/net-reactor-support/browse_thread/thre...

Denis

unread,
Sep 23, 2010, 8:25:11 PM9/23/10
to .Net Reactor Support
Nirvana,

Glen is right. In the end it is only on the .NET runtime to load the
assembly in a 32 bit or 64 bit context. No matter if you compile your
assembly as x86, x64 or AnyCPU the compiled method IL code is always
the same. And the difference between a x86 and AnyCPU compiled
assembly is only a single bit. The difference between a x86/AnyCPU and
a x64 assembly are few bytes.

If I use the mentioned tool "InspectExe" on a AnyCPU assembly it tells
me "File is a .NET Program for Intel 386 (32bit) computers...". Maybe
this can be a bit confusing. But if you take a look on the CLR header
you will see the following:
IL Only - Yes
32bit Required - No

However, there is not difference if you execute an AnyCPU or x64
assembly on a x64 OS.

> > -http://groups.google.com/group/net-reactor-support/browse_thread/thre...
> > -http://stackoverflow.com/questions/2404469/net-reactor-how-to-protect...

nirvana

unread,
Sep 23, 2010, 10:05:20 PM9/23/10
to .Net Reactor Support
Hi Glen,

I appreciate you taking time in responding.

There are scenarios where you can not settle with just a single Any
CPU build (for example, your product may need to support multiple
target platforms and it may have 3rd party dependent components which
are not .Net assemblies and strictly 32 bit or 64 bit).

Dennis has already acknowledged the issue in his post. It would save
us a lot of time if this behavior was documented somewhere in .Net
Reactor help file or release notes etc.

Thanks for participating in this forum - I'm sure this will make the
Reactor even a better product.

Regards.
> > -http://groups.google.com/group/net-reactor-support/browse_thread/thre...
> > -http://stackoverflow.com/questions/2404469/net-reactor-how-to-protect...

Denis

unread,
Sep 24, 2010, 1:56:05 PM9/24/10
to .Net Reactor Support
Nirvana,

If you can show me only one case where an AnyCPU assembly would not
work but the corresponding X64 assembly would, I will move your
request on top of the todo list. The only advantage of an x64 assembly
I can see - it declines to run on a x86 OS.

Thank you.

Denis

unread,
Sep 25, 2010, 11:35:21 PM9/25/10
to .Net Reactor Support
Nirvana,

If you can show me only one case where a x64 assembly would work and
the corresponding AnyCPU assembly would not, I will move your request
on top of the todo list!

Greetings

On 24 Sep., 04:05, nirvana <suman.das...@gmail.com> wrote:

nirvana

unread,
Oct 7, 2010, 9:37:17 PM10/7/10
to .Net Reactor Support
Hi Denis,

As mentioned, we have some 3rd party dependent components which are
not .Net assemblies and strictly 32 bit or 64 bit (not Any CPU). Thus
if we have an Any CPU build it runs as 32bit app in a 32bit OS and
x64bit in a 64bit OS. The problem starts whenever it tries to load
the 3rd party assemblies. It would be better if the user is given
this feedback earlier rather than waiting till it needs to load the
3rd party assemblies.

The other issue is, it is logical to retain the bitness of the
assemblies - changing x64 assemblies to Any CPU does not make sense.

For now this is not a major issue for us other that the fact that
people accidentally installing Any CPU build on a 32bit OS and then
later on realizing that part of the product wont work as it requires
loading 32-bit 3rd party components.

Regards.

Denis

unread,
Oct 9, 2010, 12:42:46 AM10/9/10
to .Net Reactor Support
Hi Nirvana,

Real x64 output will be available in short. :)

Greetings,

Denis
Reply all
Reply to author
Forward
0 new messages