Sign in to follow this  
gorgorath

[java] obfuscating code

Recommended Posts

are there any free programs that will let me obfuscate the code, or other alternatives..like creating classes only compatible with x86 or so tia Paul

Share this post


Link to post
Share on other sites
Quote:
Original post by gorgorath
are there any free programs that will let me obfuscate the code,


ProGuard

Quote:
Original post by gorgorath
like creating classes only compatible with x86 or so


I'm not sure possibly you can get something to put a class in an exe file, but this kinda defeats the point of JAVA.

Share this post


Link to post
Share on other sites
You can use ProGuard, JODE or RetroGuard. You can use jsmooth to wrap your classes into an executable.

Please note that such actions are fairly childish, though, as your work is perfectly protected by copyright law and needs no other safeguards to be "yours".

Share this post


Link to post
Share on other sites
I don't seem much point in doing that. What's the harm if someone gets a look at the source code? Even if you could obfuscate it, the same results could be reproduced without getting a look at the source code, or any reverse engineering at all. I think this falls into the "mostly pointless" category, as well as the "mostly futile" category.

Share this post


Link to post
Share on other sites
Use of the obfuscators such as Proguard is:

- To discourage reverse engineering (i.e. unauthorised modification) of classfiles (It does make it quite a bit harder, but still not massively difficult).
- To reduce the size of .jar files - particularly important for J2ME games
- CAN make the application load faster - some obfuscators also do a certain amount of optimisation. I believe that proguard can inline some methods (and maybe constants), plus removes dead code.

Mark

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Quote:
Original post by markr
Use of the obfuscators such as Proguard is:

- To discourage reverse engineering (i.e. unauthorised modification) of classfiles (It does make it quite a bit harder, but still not massively difficult).
- To reduce the size of .jar files - particularly important for J2ME games
- CAN make the application load faster - some obfuscators also do a certain amount of optimisation. I believe that proguard can inline some methods (and maybe constants), plus removes dead code.

Mark

I believe you mean optimization with a 'z'.

And can't you just encrypt your .jar files?

And for optimizations javac does provide a few more now with jdk 1.5 than previously available.

Share this post


Link to post
Share on other sites
Quote:
Original post by Anonymous Poster
I believe you mean optimization with a 'z'.


Not all the world is American! Many of us (For example, Australia and the UK) spell it "optimisation". Another example is "colour", not "color".

I'm not sure why Americans had to be different but I guess thats the way they are.

Share this post


Link to post
Share on other sites
Quote:
Original post by Anonymous Poster
And can't you just encrypt your .jar files?


And what will decrypt these files. You'll need a key built into the software somewhere. In that case, it'll only prevent the most casual attempts at reverse engineering.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Quote:
Original post by firesoft
Quote:
Original post by Anonymous Poster
I believe you mean optimization with a 'z'.


Not all the world is American! Many of us (For example, Australia and the UK) spell it "optimisation". Another example is "colour", not "color".

I'm not sure why Americans had to be different but I guess thats the way they are.


yeah I was aware of the difference and why he chose to use s instead of z such as civilisation, neighbour, initialisation, etc...

I don't know why American English is different you'd have to ask the puritains. Personally I find the difference extremely annoying.

jonahrowley:
Good discussion on encrypting jars and the final conclusion there was that there is no 'standard' way to encrypt them.

I guess I was thinking of singed jar files. Thus creating a legal means from copyright protection. Still doesn't help though in the way of a very proprietary algorithm that you want to protect.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Dang it all forgot the alternate text for the hyperlink.
Discussion mentioned above!

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
http://forum.java.sun.com/thread.jspa?threadID=451830&start=0&tstart=0

PS would a moderator please be so kind as to delete those stupid posts for me! Thanks!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this