There seems to be no code for Objective-C for the obfuscator. But suppose for a moment that it exists.
Apple will probably not give up the running application if it does not work. The main question: what is the meaning of obfuscation? Usually you want to obfuscate the code to protect your knowledge, for example, if your program uses copy protection that you want to complicate for a potential cracker, or if you use some advanced algorithm, you do not want business competitors to be able to decompile him.
Copy protection has already taken care of iOS. Although through jailbreaking a normal application can be copied and launched, I would say that the actual number of users who do this is quite low (at least much lower than on regular computers such as PCs and Macs). Do you expect piracy to have such a big problem that you need to confuse?
If you have important knowledge to protect, then obfuscation can be helpful. Obfuscation has its drawbacks: you can no longer debug your tangled application. Crash reports will be useless.
You can also read Obfuscating Cocoa's article.
Let's get back to the fact that there seems to be no obfuscator: what you can do is a trick: let's say you have a headline like this:
@interface MyClass : NSObject { } - (void)myMethod;
You can do cheap obfuscation as follows:
#ifndef DEBUG #define MyClass aqwe #define myMethod oikl #endif @interface MyClass : NSObject { } - (void)myMethod;
This way, you can use significant characters in your source, but the compiler will turn it into "garbage" when it is not compiled for debugging.
DarkDust Apr 05 '11 at 19:17 2011-04-05 19:17
source share