Obfuscate javascript code

I have obfuscated my JS code in javascriptobfuscator.com , but my surprise is that in tools like http://www.jsnice.org / , putting the obfuscated code decrypts it to you practically 100% in a moment.

Is there any way to obfuscate the code and that it cannot be decrypted?

 1
Author: J. Joe, 2016-06-20

4 answers

Is there a way to obfuscate the code and that it cannot be decrypted?

there is NO, for obfuscating is the transformation of a piece of code into another code: difficult to read for a person, but equivalent for a machine . Although it is not fully reversible (the original names of variables and functions will be lost) it still generates the same results and even if there are no such clues, it will still be relatively easy to parse how it works.

Obfuscation is a form of security by darkness, and is not considered a good practice as does not remove the attack vector you would simply be covering/hiding it.

The way to secure a system-any system-is to do it in its design; by hiding the code, you just make it a little harder to find a vulnerability but the vulnerability is still there.

 11
Author: rnrneverdies, 2016-06-21 19:14:35

The idea of obfuscating is to make it difficult to understand or read, just add a few more steps to the process of understanding your code, but it does not refer to making it impossible to understand. If it were impossible, how would the browser interpret it?

As @learnercys indicates, it's best to avoid sensitive data on the client side, try to keep your system logic separate from the presentation.

 4
Author: JYass, 2016-06-20 23:21:15

I think this tool does better what you want to do, and leaves the code unrecognizable. ( http://www.danstools.com/javascript-obfuscate / ) see if it serves you @ DavidMatas

 0
Author: Marc Lemien, 2016-07-22 20:32:08

I'm also researching how to make it more difficult to understand and copy. As you say, this tool http://javascriptobfuscator.com / apparently does a good obfuscation but it's easy to get the code almost 100% de-obfuscated. A friend suggested this page http://myobfuscate.com / , you could try it. Others recommended me a paid option like JScrambler but I haven't gotten to try it yet.

 0
Author: TheoXT, 2016-10-12 03:10:58