Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Protect C# Source Code

Protect C# Source Code

Scheduled Pinned Locked Moved C#
csharpc++toolshelpquestion
5 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Razer
    wrote on last edited by
    #1

    I have just spent about 3 months writing a program for PocketPC and a PC version in C# just to find out that within seconds it can be decompiled into readable source code. Does that not bother anyone else but me? I know it's my fault for not checking out the language more before starting but I need a way to protect my code. Any ideas. I am a single programmer selling software and I can't afford the expensive obfuscation tools. Any help would be appreciated. If I can't get a work around I will have to rewrite the application in c++. Thanks.

    M H N 3 Replies Last reply
    0
    • R Razer

      I have just spent about 3 months writing a program for PocketPC and a PC version in C# just to find out that within seconds it can be decompiled into readable source code. Does that not bother anyone else but me? I know it's my fault for not checking out the language more before starting but I need a way to protect my code. Any ideas. I am a single programmer selling software and I can't afford the expensive obfuscation tools. Any help would be appreciated. If I can't get a work around I will have to rewrite the application in c++. Thanks.

      M Offline
      M Offline
      Mike Ellison
      wrote on last edited by
      #2

      Hi. You can use an obfuscator tool on your assemblies. Do a web search for ".net obfuscator" and you'll find a bunch. I just read your message more carefully. I don't know of a freeware obfuscation tool... keep searching though - there may be one out there.

      J 1 Reply Last reply
      0
      • M Mike Ellison

        Hi. You can use an obfuscator tool on your assemblies. Do a web search for ".net obfuscator" and you'll find a bunch. I just read your message more carefully. I don't know of a freeware obfuscation tool... keep searching though - there may be one out there.

        J Offline
        J Offline
        jconwell
        wrote on last edited by
        #3

        Obfuscator tools wont really help you out much in this area. It might dissuade people who aren’t very driven to see how your code works, but for every obfuscator out there, there is a de-obfuscator that will unscramble the code. Besides, from my understanding, an obfuscator just scrambles the local variable names, to make it harder to follow the code. But the basic code; if, else, for, switch statements, as well as Function calls will still be very clear to read. I’ve looked at obfucatored code before using Anikrino and was still able to follow the algorithm used. john C

        1 Reply Last reply
        0
        • R Razer

          I have just spent about 3 months writing a program for PocketPC and a PC version in C# just to find out that within seconds it can be decompiled into readable source code. Does that not bother anyone else but me? I know it's my fault for not checking out the language more before starting but I need a way to protect my code. Any ideas. I am a single programmer selling software and I can't afford the expensive obfuscation tools. Any help would be appreciated. If I can't get a work around I will have to rewrite the application in c++. Thanks.

          H Offline
          H Offline
          Heath Stewart
          wrote on last edited by
          #4

          This is the problem with knowing a language/syntax and knowing a technology. All language compilers targeting the CLR compile to IL (so the source language really doesn't matter, sans some specific compiler optimizations), which is in many ways like assembler. The IL is JIT'd to native code and executed. Of course it can be disassembled. But any good programs should fear very little. Copyright your work and make a good product that users want to buy, not buy because they don't really have any better choices. There are many programs out there written in .NET. Heck, Java is no different. If you're using cryptography anywhere, it's always been said and written by leading cryptoanalysts that the best cryptographic libraries are open. Your algorithms should be so good that you don't need to depend on data-hiding. Finally, if pieces of your application are really so important and you can't deal with the fact that some schmoe wants to copy pieces of it, make a native library and P/Invoke the functions (or, if using COM, create an RCW for your native COM object). This way, the majority of your application is still managed (which mainly gets that name from its memory management capabilities) and is faster to write and maintain. Just something to think about.

          -----BEGIN GEEK CODE BLOCK----- Version: 3.21 GCS/G/MU d- s: a- C++++ UL@ P++(+++) L+(--) E--- W+++ N++ o+ K? w++++ O- M(+) V? PS-- PE Y++ PGP++ t++@ 5 X+++ R+@ tv+ b(-)>b++ DI++++ D+ G e++>+++ h---* r+++ y+++ -----END GEEK CODE BLOCK-----

          1 Reply Last reply
          0
          • R Razer

            I have just spent about 3 months writing a program for PocketPC and a PC version in C# just to find out that within seconds it can be decompiled into readable source code. Does that not bother anyone else but me? I know it's my fault for not checking out the language more before starting but I need a way to protect my code. Any ideas. I am a single programmer selling software and I can't afford the expensive obfuscation tools. Any help would be appreciated. If I can't get a work around I will have to rewrite the application in c++. Thanks.

            N Offline
            N Offline
            Nick Seng
            wrote on last edited by
            #5

            Just something to add. VS.Net 2003 comes with a free obsfucator.


            "if you vote me down, I shall become more powerful than you can possibly imagine" - Michael P. Butler. Support Bone It's a weird Life

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups