Questions tagged [obfuscation]

Obfuscation is the process by which the code is altered so that a developer finds it much harder to understand clearly what the intended program does or how it operates. The larger the program the greater the obfuscation, as code becomes intertwined linking different segments through out the program.

While it may be possible to use a disassembler to figure out how certain aspects within a program function, it requires knowledge of assembly. Assembly language by its nature is non-trivial.

Another way to increase obfuscation is to use packers.

2987 questions
126
votes
12 answers

How do I hide javascript code in a webpage?

Is it possible to hide the Javascript code from the html of a webpage, when the source code is viewed through the browsers View Source feature? I know it is possible to obfuscate the code, but I would prefer it being hidden from the view source…
arun nair
  • 3,643
  • 14
  • 41
  • 49
114
votes
10 answers

Best Java obfuscator?

I am developing a security software and want to obfuscate my java code so it will become impossible to reverse engineer. What is the most reliable java obfuscator ?
Xinus
  • 29,617
  • 32
  • 119
  • 165
112
votes
5 answers

Enabling ProGuard in Eclipse for Android

The new documentation on ProGuard for Android says to add a line to the default.properties file in the project home directory. However, on opening this file, I read at the top: # This file is automatically generated by Android Tools. # Do not…
Ted Hopp
  • 232,168
  • 48
  • 399
  • 521
102
votes
14 answers

Techniques for obscuring sensitive strings in C++

I need to store sensitive information (a symmetric encryption key that I want to keep private) in my C++ application. The simple approach is to do this: std::string myKey = "mysupersupersecretpasswordthatyouwillneverguess"; However, running the…
Thomi
  • 11,647
  • 13
  • 72
  • 110
93
votes
7 answers

Is it possible to decompile an Android .apk file?

Are the users able to convert the apk file of my application back to the actual code? If they do - is there any way to prevent this?
aryaxt
  • 76,198
  • 92
  • 293
  • 442
93
votes
9 answers

Prevent class member name obfuscation by ProGuard

I have my class ClassMultiPoint with subclasses. public class ClassMultiPoints { public String message; public List data; public class ClassPoints { public String id; public List points; …
Tapa Save
  • 4,769
  • 5
  • 32
  • 54
84
votes
6 answers

This obfuscated C code claims to run without a main(), but what does it really do?

#include #define decode(s,t,u,m,p,e,d) m##s##u##t #define begin decode(a,n,i,m,a,t,e) int begin() { printf("Ha HA see how it is?? "); } Does this indirectly call main? how?
Rajeev Singh
  • 3,292
  • 2
  • 19
  • 30
84
votes
23 answers

How to hide a string in binary code?

Sometimes, it is useful to hide a string from a binary (executable) file. For example, it makes sense to hide encryption keys from binaries. When I say “hide”, I mean making strings harder to find in the compiled binary. For example, this…
Dmitriy
  • 3,305
  • 7
  • 44
  • 55
77
votes
11 answers

Best solution to protect PHP code without encryption

First of all, I'm not looking for miracle... I know how PHP works and that there's not really way to hide my code from the clients without using encryption. But that comes with the cost of an extension to be installed on the running server. I'm…
rfgamaral
  • 16,546
  • 57
  • 163
  • 275
75
votes
5 answers

iPhone/iPad App Code Obfuscation - Is it Possible? Worth it?

I've researched quite a bit, both on SO, as well google-ing all over the place, but I can't seem to find a straight-forward answer in regards to code obfuscation for iPhone/iPad apps written in Objective-C. My questions are these: Is there a way to…
bpatrick100
  • 1,261
  • 1
  • 15
  • 23
75
votes
1 answer

What does the -> <- operator do?

I recently came upon the following code: IntPredicate neg = x -> x <- x; What is this, some sort of reverse double lambda?
fredoverflow
  • 256,549
  • 94
  • 388
  • 662
72
votes
5 answers

How to debug with obfuscated (with ProGuard) applications on Android?

When I got something like this ERROR/AndroidRuntime(18677): Caused by: java.lang.NullPointerException ERROR/AndroidRuntime(18677): at com.companyname.a.a.a(Unknown Source) How can I know where the problem is and debug this issue? I only got the…
shiami
  • 7,174
  • 16
  • 53
  • 68
70
votes
5 answers

Secure distribution of NodeJS applications

What: Can NodeJS apps be distributed as binary? ie. you compile the .js app via V8 into its native binary, and distribute the binary to clients? (if you had total access to the NodeJS server)... or is minifying the code all you can do? Why: We build…
Robin Rodricks
  • 110,798
  • 141
  • 398
  • 607
66
votes
3 answers

How does this magic JavaScript code work?

This is a small piece of JavaScript code that alerts "Hello…
Tony Dinh
  • 6,668
  • 5
  • 39
  • 58
66
votes
5 answers

Simplest way to obfuscate and deobfuscate a string in JavaScript

I'm looking for a way to obfuscate and deobfuscate a string in JavaScript; by which I mean encryption and decryption when security is not an issue. Ideally something native to JS (like base64_encode() and base64_decode() in PHP) to "turn a string…
Rich Jenks
  • 1,723
  • 5
  • 19
  • 32