1

I have a bookmarklet, and i want to hide/encode the JavaScript code within, something like a compiled code, so that the original code wont be available for the users of the bookmarklet;

Can i do this, and if yes, how ?

Ionică Bizău
  • 109,027
  • 88
  • 289
  • 474
Ionut Flavius Pogacian
  • 4,750
  • 14
  • 58
  • 100

1 Answers1

1

Maybe this site can help you: http://www.javascriptobfuscator.com/

About it:

Free Javascript Obfuscator is a professional tool for obfuscation of javascript. It Converts JavaScript source code into scrambled and completely unreadable form, preventing it from analysing and theft.

I gave it this input test:

alert("Hello World")

Output:

var _0x7d3e=["\x48\x65\x6C\x6C\x6F\x20\x57\x6F\x72\x6C\x64"];alert(_0x7d3e[0]);

You can test it in your Firefox Scratchpad (Shift + F4) or in Google Chrome console (F12).

Ionică Bizău
  • 109,027
  • 88
  • 289
  • 474
  • This is from [About Page](http://www.javascriptobfuscator.com/Javascript-Obfuscator.aspx). I don't understand what you mean. – Ionică Bizău Jan 12 '13 at 18:58
  • Meaning that would take someone about 2 seconds to decode. As obfuscatiors go, (and this is a fools errand anyway) it's not a very good one. – steveax Jan 12 '13 at 19:04