| View previous topic :: View next topic |
| Author |
Message |
NINTENDO Grandmaster Cheater Supreme
Reputation: 0
Joined: 02 Nov 2007 Posts: 1371
|
Posted: Fri Sep 10, 2010 8:44 am Post subject: So i've heard about this thing called .net |
|
|
Some people say that .net is not secure and that you can easily get the source code if it is not obfuscated. Is this true? and How would I hack my own app to get it's source code after I have released it.
Thx
Me
_________________
Intel over amd yes. |
|
| Back to top |
|
 |
Slugsnack Grandmaster Cheater Supreme
Reputation: 71
Joined: 24 Jan 2007 Posts: 1857
|
Posted: Fri Sep 10, 2010 9:41 am Post subject: |
|
|
As with most interpreted languages, .NET applications tend to be easily decompilable. This is not the same as getting the source code. You can quite possibly get something that looks very very similar to the source code however. You will on the other hand, lose a lot of the things that make the source useful, symbol names, etc.
To try it out simply find a decompiler and put your application through it. Reflector is an example of a .NET decompiler.
|
|
| Back to top |
|
 |
hcavolsdsadgadsg I'm a spammer
Reputation: 26
Joined: 11 Jun 2007 Posts: 5801
|
Posted: Fri Sep 10, 2010 2:27 pm Post subject: |
|
|
you can definitely pick apart obfuscated stuff but it's kinda tedious.
you'd probably end up with a bunch of stuff that looks like:
a.f();
b.f();
a.d = c;
|
|
| Back to top |
|
 |
Jani Grandmaster Cheater
Reputation: 2
Joined: 29 Dec 2006 Posts: 804
|
Posted: Fri Sep 10, 2010 3:39 pm Post subject: |
|
|
| slovach wrote: | you'd probably end up with a bunch of stuff that looks like:
a.f();
b.f();
a.d = c; |
| Code: | if( c.f() == 0x12345678 )
c::a("Thanks for buying MyProgram"); | :P
|
|
| Back to top |
|
 |
Jorg hi I post too much
Reputation: 7
Joined: 24 Dec 2007 Posts: 2276 Location: Minnesota
|
|
| Back to top |
|
 |
atom0s Moderator
Reputation: 205
Joined: 25 Jan 2006 Posts: 8587 Location: 127.0.0.1
|
Posted: Fri Sep 10, 2010 8:01 pm Post subject: |
|
|
Stock compiled applications with .NET have no security at all. Hard coding anything like passwords or other sensitive information is completely pointless and will just lead to your program being cracked in minutes.
You can obfuscate your program, but it only adds a minor level of security to the program, and most of the obfuscators have deobfuscators already made. Some wont work on large scale projects, but for the most part you can still easily debug something that's obfuscated and manage to get what you need.
If you wish to learn more about .NET specifically:
http://www.microsoft.com/net/
http://en.wikipedia.org/wiki/.NET_Framework
If you are looking into coding with .NET, I would personally suggest and recommend using Visual Studio. Which you can download the free Express edition from Microsoft:
http://www.microsoft.com/express/
_________________
- Retired. |
|
| Back to top |
|
 |
AhMunRa Grandmaster Cheater Supreme
Reputation: 27
Joined: 06 Aug 2010 Posts: 1117
|
Posted: Fri Sep 10, 2010 10:09 pm Post subject: |
|
|
.NET is a decent platform, you can develop web apps literally in minutes that would take alot longer in other languages.
Reflector will decompile .NET code and it does give somewhat of an idea what the code is doing. I have seen other decompilers that are much better than Reflector for .NET even going so far as to break down functions into something more readable.
Of course the functions and any variables that go along with it are all along the lines of func1(vara, varb, stringa); but it still does one hell of a job.
For the record, there is a difference between machine code and source.
_________________
<Wiccaan> Bah that was supposed to say 'not saying its dead' lol. Fixing >.> |
|
| Back to top |
|
 |
Jorg hi I post too much
Reputation: 7
Joined: 24 Dec 2007 Posts: 2276 Location: Minnesota
|
|
| Back to top |
|
 |
atom0s Moderator
Reputation: 205
Joined: 25 Jan 2006 Posts: 8587 Location: 127.0.0.1
|
|
| Back to top |
|
 |
Polynomial Grandmaster Cheater
Reputation: 5
Joined: 17 Feb 2008 Posts: 524 Location: Inside the Intel CET shadow stack
|
Posted: Mon Sep 13, 2010 8:02 pm Post subject: |
|
|
You can use {smartassembly} to obfuscate your .NET binaries. The result is immensely difficult to de-mung since names entirely made up of non-ascii characters are selected. It also offers control flow obfuscation (e.g. replacing function calls with reflection invokes, adding proxy methods, etc) which makes the flow of the program difficult to understand. It also has the ability to insert jargon streams into the binary and mess with the headers to fool debuggers and decompilers. There's also other options such as string encryption and modification protection.
The great thing is that it saves a name translation database during the obfuscation process, and it comes with an addon for VS that allows you to debug with the names automatically de-munged.
_________________
It's not fun unless every exploit mitigation is enabled.
Please do not reply to my posts with LLM-generated slop; I consider it to be an insult to my time. |
|
| Back to top |
|
 |
TROLOLOLOLOLOLOLOLOLOLOLO Expert Cheater
Reputation: -1
Joined: 27 Dec 2009 Posts: 100
|
Posted: Mon Sep 13, 2010 9:16 pm Post subject: |
|
|
| Burningmace wrote: | You can use {smartassembly} to obfuscate your .NET binaries. The result is immensely difficult to de-mung since names entirely made up of non-ascii characters are selected. It also offers control flow obfuscation (e.g. replacing function calls with reflection invokes, adding proxy methods, etc) which makes the flow of the program difficult to understand. It also has the ability to insert jargon streams into the binary and mess with the headers to fool debuggers and decompilers. There's also other options such as string encryption and modification protection.
The great thing is that it saves a name translation database during the obfuscation process, and it comes with an addon for VS that allows you to debug with the names automatically de-munged. |
There is also De Smart, which undoes everything that does.
|
|
| Back to top |
|
 |
InternetIsSeriousBusiness Grandmaster Cheater Supreme
Reputation: 8
Joined: 12 Jul 2010 Posts: 1268
|
Posted: Mon Sep 13, 2010 9:19 pm Post subject: |
|
|
I like C++ .net the best.
_________________
FLAME FLAME FLAME!!!@@@ |
|
| Back to top |
|
 |
Polynomial Grandmaster Cheater
Reputation: 5
Joined: 17 Feb 2008 Posts: 524 Location: Inside the Intel CET shadow stack
|
Posted: Tue Sep 14, 2010 8:36 am Post subject: |
|
|
| CometJack wrote: | | There is also De Smart, which undoes everything that does. |
Not quite, since you can't demung the names to anything but random ascii names still. And the control flow obfuscation can't be fully undone, since reflection invokes can be done by input code as well as smartassembly's stuff - there's no way to detect which invokes were which.
_________________
It's not fun unless every exploit mitigation is enabled.
Please do not reply to my posts with LLM-generated slop; I consider it to be an insult to my time. |
|
| Back to top |
|
 |
atom0s Moderator
Reputation: 205
Joined: 25 Jan 2006 Posts: 8587 Location: 127.0.0.1
|
Posted: Tue Sep 14, 2010 3:58 pm Post subject: |
|
|
| CometJack wrote: | | Burningmace wrote: | You can use {smartassembly} to obfuscate your .NET binaries. The result is immensely difficult to de-mung since names entirely made up of non-ascii characters are selected. It also offers control flow obfuscation (e.g. replacing function calls with reflection invokes, adding proxy methods, etc) which makes the flow of the program difficult to understand. It also has the ability to insert jargon streams into the binary and mess with the headers to fool debuggers and decompilers. There's also other options such as string encryption and modification protection.
The great thing is that it saves a name translation database during the obfuscation process, and it comes with an addon for VS that allows you to debug with the names automatically de-munged. |
There is also De Smart, which undoes everything that does. |
There are a few deobfuscators for SmartAssembly but none of them are really fully designed to handle large scale projects. Most of the time the people whom write them just obfuscate a small "hello world" app and work with that. Which kind of makes their tool a bit useless on bigger projects.
I use SmartAssembly for work and so far, none of the deobfuscators work on any of our projects. They all crash before it can get anywhere with deobfuscating the programs. Not to say they will never work, but they currently done.
Anyway, using things like obfuscation is just a minor security boost. It helps keep those whom only know basics out. While it will never be a 100% secure method to protect your application(s), there is nothing that will. Any bit of security you can add helps, regardless.
Overall, just keep sensitive data out of the executable/modules that are done in .NET and use other means to store any data that is important. Use web services when you can if you need to and so on as well.
_________________
- Retired. |
|
| Back to top |
|
 |
Polynomial Grandmaster Cheater
Reputation: 5
Joined: 17 Feb 2008 Posts: 524 Location: Inside the Intel CET shadow stack
|
Posted: Wed Sep 15, 2010 8:06 am Post subject: |
|
|
| Wiccaan wrote: | | Overall, just keep sensitive data out of the executable/modules that are done in .NET and use other means to store any data that is important. Use web services when you can if you need to and so on as well. |
There's a few reasons why you shouldn't do that. Firstly it requires you to mix managed an unmanaged code, which is a pretty bad idea. Second, reverse engineers are often very adept at attacking C++/C binaries. Web services can be a vulnerability too, since standard framework code is easy to hook in order to find the HTTP buffer, even when HTTPS is used.
If you want to keep your strings secure, store them in a custom database format that is encrypted and read them out as and when they are needed at runtime. You can also use the SecureString class to store data in the protected storage of the OS.
_________________
It's not fun unless every exploit mitigation is enabled.
Please do not reply to my posts with LLM-generated slop; I consider it to be an insult to my time. |
|
| Back to top |
|
 |
|