473,385 Members | 2,162 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Protecting your code

I saw an old thread in this group which addressed the issue of reverse
compilation. After some study, I draw a conclusion that "reverse
compilation" is completely blocked off in win32 environment (except in .NET
languages like C#) because (in the worst case) when you tried to figure out
what has been done on a C++ program. The answer was already precomputed by
the compiler on the author's side. So you never get the algorithm.
For example,
If someone knows how to optimize code
int main (int argc, char *argv[])
{
int i,j, k[10];

i = 0;
j = 20;
i = j * 3;
return 0;
}

What you will get when you "debug" the program

push 0x3c (60)
call printf

So you get nothing out of it... needless to say .NET which is a stronger
compiler than ever.

So It is the most secure to write code in Win32 environment since all the
info is destroyed

The above is my personal opinion!
Nov 17 '05 #1
2 994
Jacky Luk <jl@knight.com> wrote:
I saw an old thread in this group which addressed the issue of reverse
compilation. After some study, I draw a conclusion that "reverse
compilation" is completely blocked off in win32 environment (except in .NET
languages like C#) because (in the worst case) when you tried to figure out
what has been done on a C++ program. The answer was already precomputed by
the compiler on the author's side. So you never get the algorithm.
Only when things *can* be precomputed by the compiler. This isn't the
case in most applications with any significant algorithms.

<snip>
So It is the most secure to write code in Win32 environment since all the
info is destroyed


Yes, information is removed if the compiler can do it all at compile-
time. Care to show any *real world* examples of sensitive algorithms
which can be evaluated entirely at compile-time? Bear in mind that most
algorithms need to take parameters which are used in the computation...

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #2
"Jacky Luk" <jl@knight.com> wrote in message
news:OK**************@TK2MSFTNGP14.phx.gbl...
So It is the most secure to write code in Win32 environment since all the
info is destroyed


Even if this was true, I am continually amazed at people who are so hung up
about reverse engineering. I'm of the opinion that time spent worrying about
this, working on it, or "resolving" it is time wasted. Working out what a
program does is hard, especially without documentation or comments. Even if
a competitor decided to use your code base they would still be behind. Your
development would be spending time creating new versions, and adding
functionality, whilst the competitor would be spending all their time
reverse engineering old code, and trying desperately to handle bugs they
could not understand.
Nov 17 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

24
by: Yang Li Ke | last post by:
Hi guys! Anyone know a way so that users purchasing my scripts would not be able to share them with other people ? Yang
18
by: Alan Sheehan | last post by:
Hi pythonistas, I am looking for methods of deploying applications with end users so that the python code is tamper proof. What are my options ? I understand I can supply .pyc or .pyo files...
6
by: nell | last post by:
Hi all, I've developed a testing application in python, and should supply it in a way that no one (lets say they are regular users) will understand it and edit it. The application source is all...
12
by: Roland Hall | last post by:
I read Aaron's article: http://www.aspfaq.com/show.asp?id=2276 re: protecting images from linked to by other sites. There is a link at the bottom of that page that references an interesting...
5
by: John | last post by:
Dear all, I've got a security question that is so difficult that "maybe" there will be no answer for it. It's regarding protecting asp code. I did write some asp code, that I sell to...
7
by: Shawn | last post by:
Hi. I have a folder that contains a lot of different documents. xls, .doc, .pdf etc. Different users have access to different documents. The problem is that if a user knows the name of a...
12
by: Dr. Edmund M. Hayes | last post by:
I wrote a access program that works well enough that a handful of people would like to buy it from me. My problem is that if I sell it to someone there is no mechanism that I know of to protect...
22
by: flit | last post by:
Hello All, I have a hard question, every time I look for this answer its get out from the technical domain and goes on in the moral/social domain. First, I live in third world with bad gov., bad...
0
by: xamman | last post by:
hi there! according to msdn (link at bottom) i should be able to protect a whole class declaratively as above. However i keep getting 'request for principal permissions failed' exceptions. in...
16
by: rogerjames1 | last post by:
How would I go about protecting a whole directory, e.g. http://www.example.com/members/ and all sub-directories with login protection? I wouldn't like to put a .php script in each directory and...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.