Skip to main content
GameDev.net gamedev.net
🔒 Locked

Managed or native executable?

Started by Russell Apr 19, 2004 at 12:30 AM 3 replies 850+ views
Original Post
Russell
Russell
Is there any way to tell whether an executable is a managed .net executable, or a natively compiled executable? Hopefully something aside from uninstalling the .net runtime and seeing if it will run or not
antareus
antareus
Depends.exe. If you see mscoree.dll then it is a .NET app.
--God has paid us the intolerable compliment of loving us, in the deepest, most tragic, most inexorable sense.- C.S. Lewis
Russell
Russell
Ah yeah, thanks. I remember using that once upon a time.
Alias2
Alias2
The traditional way is to just run ildasm.exe on the assembly. If it''s not a managed assembly, it will fail accordingly.

I''m assuming from the other posts that you wanted a way to test by hand. If you want a way to test programmatically there are ways of doing that as well.

Suzanne listed both the "by hand" and programmable options in her blog: http://weblogs.asp.net/suzcook/archive/2004/03/17/91715.aspx
Jan Wassenberg
Jan Wassenberg
Assuming you want to do it from code: see check_managed_app() in crt0.c Digging around always pays off Not sure how far into undocumented land this takes you, though.
E8 17 00 42 CE DC D2 DC E4 EA C4 40 CA DA C2 D8 CC 40 CA D0 E8 40E0 CA CA 96 5B B0 16 50 D7 D4 02 B2 02 86 E2 CD 21 58 48 79 F2 C3

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.