1. #1
    Sencha User talha06's Avatar
    Join Date
    Jul 2009
    Location
    Turkey
    Posts
    303
    Vote Rating
    0
    talha06 is on a distinguished road

      0  

    Question Javascript Obfuscator [which can also bypass Firebug]

    Javascript Obfuscator [which can also bypass Firebug]


    Hello to everyone,

    In my project, I need to obfuscate my scripts. While I was searching I found some useful tools except YUI Compressor that does this but I just want to learn how can I also hide my script code from Firebug? Are there anyone who knows a way to do this?

    Thanks in advance..
    "People will never forget how you made them feel."
    linkedin.com/in/talhakabakus

  2. #2
    Ext JS Premium Member
    Join Date
    Aug 2007
    Location
    Antwerp, Belgium
    Posts
    555
    Vote Rating
    27
    joeri has a spectacular aura about joeri has a spectacular aura about joeri has a spectacular aura about

      0  

    Default


    It can't be done, and anyone claiming they can is selling you snake oil.

    Also, it doesn't need to be done. Obfuscation is usually needed for two reasons: (1) security, and (2) management fear of stolen code.
    - Security is a bad reason because this points to mistakes made in the security architecture of the application, so the developer is at fault for thinking they need the obfuscator in the first place.
    - Fear of stolen code is also a bad reason because javascript code pretty much never gets stolen if minified, not even if it's google's code (and most of the obfuscated code simply isn't valuable enough to steal).

  3. #3
    Sencha User talha06's Avatar
    Join Date
    Jul 2009
    Location
    Turkey
    Posts
    303
    Vote Rating
    0
    talha06 is on a distinguished road

      0  

    Default


    I need this in order to prevent code stealing. As I know 'minify' just compresses the code; but it is still readable without using anything. I need to 'pack'(compress + obfuscate) my scripts. I do all security stuff at server-side..
    "People will never forget how you made them feel."
    linkedin.com/in/talhakabakus

  4. #4
    Ext JS Premium Member
    Join Date
    Aug 2007
    Location
    Antwerp, Belgium
    Posts
    555
    Vote Rating
    27
    joeri has a spectacular aura about joeri has a spectacular aura about joeri has a spectacular aura about

      0  

    Default


    Why do you think people would steal your code?

  5. #5
    Sencha User talha06's Avatar
    Join Date
    Jul 2009
    Location
    Turkey
    Posts
    303
    Vote Rating
    0
    talha06 is on a distinguished road

      0  

    Default


    Actually this is not just I want. This is also what the people that is going to use it wants.. I think there are many people who wants this, otherwise there wouldn't any obfuscating tools..
    "People will never forget how you made them feel."
    linkedin.com/in/talhakabakus

  6. #6
    Sencha Premium Member
    Join Date
    Feb 2009
    Posts
    316
    Vote Rating
    3
    azuroff will become famous soon enough

      0  

    Default


    If you don't want your code to be stolen, don't send it to the user's browser. Period. Obfuscating tools might make it more difficult for someone to figure out/steal your code, but that will only slow down a determined attacker - not stop them.

  7. #7

  8. #8
    Ext JS Premium Member gevik's Avatar
    Join Date
    May 2009
    Location
    The Netharlands
    Posts
    265
    Vote Rating
    8
    gevik will become famous soon enough

      0  

    Default


    Preventing people from stealing your JS code by obfuscating it, is simply not possible. The obfuscation apps out there will only make the code temporarily unreadable and somewhat difficult to disassemble, nothing more.

    If your app is going to be on the net for everyone, I would suggest to think about the data that your app is exposing on the browser and minimize the amount of unnecessary data if possible. This is one of the reasons why "select * from table"->json->Ext.data.Store is a bad idea

    On top of that, I would do the data validation on the server as much as possible. This way you can minimize the risk of executing "disabled" functionality from the firebug console.

    But usually the problem is not the code or how much of the code is exposed in the browser, the real question is whether you can trust the users of your application. To my experience solving this kind of problems starts at much higher level in the organization than at the very end at the code level.

    my 2 cents..... I hope it helps.

  9. #9
    Sencha User renku's Avatar
    Join Date
    Feb 2009
    Location
    Estonia
    Posts
    437
    Vote Rating
    17
    renku is a splendid one to behold renku is a splendid one to behold renku is a splendid one to behold renku is a splendid one to behold renku is a splendid one to behold renku is a splendid one to behold renku is a splendid one to behold

      0  

    Default


    Quote Originally Posted by ffzhuang View Post
    Ha ha. This is exactly what joeri called "snake oil". From the web page you can read that the obfuscator allows you to do three things:

    * Remove comments and whitespace
    * Compress
    * Obfuscate names.

    And for the last option it says: Warning! Use this option with caution. For example, automatic renaming of global or interface variables may cause a script malfunction, so in most cases it requires manual renaming.

    Which really means: it doesn't work.

    In fact all the well-known free JavaScript compressors already obfuscate your variable names by just renaming them with as few letters as possible. And you don't have to be cautious. Closure compiler allows you to even go way further and also optimize object property names, but that's not really an option with ExtJS.

  10. #10
    Sencha - Services Team arthurakay's Avatar
    Join Date
    Sep 2008
    Location
    Antioch, IL
    Posts
    1,353
    Vote Rating
    33
    arthurakay is a jewel in the rough arthurakay is a jewel in the rough arthurakay is a jewel in the rough

      0  

    Default


    As has been said before, the odds of anyone "stealing" your code and actually making use of it are pretty much nil.

    Think of it this way... even IF someone goes to the trouble of copy/pasting your code (whether it's minified, obfuscated, or neither), the only thing they've done is copy your client-side logic.

    In 99% of cases, that should be useless to anyone.
    - IF your UI was 100% JavaScript driven, then the theif would ONLY have a copy of your UI.
    - As most UIs are not 100% JavaScript driven, this isn't even worth worrying about
    - Your back-end would still have to duplicated perfectly for the stolen code to work

    So what exactly are you so worried about? I guarantee your project isn't worth so much money that anyone is willing to go through all of this trouble to steal your code.
    Arthur Kay
    Developer Relations Manager, Sencha Inc.

    Twitter | Sencha Chicago User Group

Similar Threads

  1. ScriptMixer: Javascript Obfuscator and Compressor
    By cracra in forum Community Discussion
    Replies: 2
    Last Post: 6 Jan 2010, 12:51 AM
  2. Firebug not showing Javascript errors
    By stevebla in forum Ext 3.x: Help & Discussion
    Replies: 5
    Last Post: 28 Sep 2009, 12:12 PM
  3. Disable Firebug javascript checking
    By deanoj in forum Community Discussion
    Replies: 4
    Last Post: 20 May 2008, 3:49 PM
  4. Javascript errors not showing in Firebug console?
    By jonathanv in forum Ext 1.x: Help & Discussion
    Replies: 6
    Last Post: 30 Jul 2007, 8:38 AM

Thread Participants: 9

Tags for this Thread

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi