Go Back   CodingForums.com > :: Client side development > JavaScript programming > JavaScript frameworks

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 02-06-2009, 02:16 PM   PM User | #1
cantthinkofanic
New Coder

 
Join Date: Jan 2008
Location: Lulworth, Dorset, England
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
cantthinkofanic is an unknown quantity at this point
Obfuscated?

I have a js file that looks like this:

//MooTools, My Object Oriented Javascript Tools. Copyright (c) 2006 Valerio Proietti, <http://mad4milk.net>, MIT Style License.
eval(function(A,G){return A.replace(/(\w+)/g,function(a,b){return G[parseInt(b,36)]})}("0 1=2(3){0 4=2(){5 (0 6 7 8){9 (8[6]) 8[6].a=8;}\n9 (b[c]....

and ends like this:

...llTop,pageYOffset,getScrollLeft,scrollLeft,pageXOffset,onDomReady,init,state,readyState,childNode s,all,navigator,taintEnabled,loaded,complete,script,_ie_ready_,write,id,defer,src,readystatechange,m yInit,callee,done,load,DOMContentLoaded".split(",")));

I want to get at the js to modify the behaviour and what it puts into the page. Is this code coded in some way?

What are my options for decoding it? (I have tried one deobfuscation tool which just repeated it back to me as is!

The file is called mootools.js and is the only file apart from slimbox.js which is a js file.
cantthinkofanic is offline   Reply With Quote
Old 02-06-2009, 08:27 PM   PM User | #2
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,292
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
You can try downloading the uncompressed version of mootools.
http://mootools.net/download
Older versions are still there as well.
Code:
http://mootools.net/download/get/mootools-x.x.x-core-nc.js
Where x.x.x is the version number. You currently have 1.1.1 so you can download the uncompressed version.
__________________
||||If you are getting paid to do a job, don't ask for help on it!||||

Last edited by _Aerospace_Eng_; 02-06-2009 at 08:33 PM..
_Aerospace_Eng_ is offline   Reply With Quote
Old 02-06-2009, 09:32 PM   PM User | #3
rnd me
Senior Coder

 
rnd me's Avatar
 
Join Date: Jun 2007
Location: Urbana
Posts: 3,553
Thanks: 9
Thanked 480 Times in 463 Posts
rnd me is a jewel in the roughrnd me is a jewel in the roughrnd me is a jewel in the roughrnd me is a jewel in the rough
you can view it by changing "eval" to "alert".

if you want to extract it, one way is to remove "eval", and assign the expression to the .value of a textarea.
__________________
my site (updated 5/13)
STATS (2013/5) HTML5:90.2% MOB:15.2% IE7:0.5% IE8:8.4% IE9:8.5% IE10:8.5%
rnd me is online now   Reply With Quote
Old 02-07-2009, 02:14 PM   PM User | #4
cantthinkofanic
New Coder

 
Join Date: Jan 2008
Location: Lulworth, Dorset, England
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
cantthinkofanic is an unknown quantity at this point
I tried the uc version but when clicking the image the lightbox did not open, just a new page with the larger image. The other js file is slimbox.js. Is this relevant? Any further advice on getting the uc 1.1.1 version working welcome.
cantthinkofanic is offline   Reply With Quote
Old 02-07-2009, 03:29 PM   PM User | #5
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,292
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
Attach your mootools.js file. You may need to put it in a zip file or link us directly to it if you can.
__________________
||||If you are getting paid to do a job, don't ask for help on it!||||
_Aerospace_Eng_ is offline   Reply With Quote
Old 02-07-2009, 04:07 PM   PM User | #6
cantthinkofanic
New Coder

 
Join Date: Jan 2008
Location: Lulworth, Dorset, England
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
cantthinkofanic is an unknown quantity at this point
Thanks, I've volunteered for a local group which I'm a member. It's better if you see the page it's on and the js file is inline. The page is:

http://www.newsite.lulworthsociety.o...d=48&Itemid=58

Click Quiz and then on the first image. Hope it's all there. PS I have copied across a mootools 1.11 version (they all fail). If you want to see the obfuscated one I will have to put it back. I would like to get a source one working.

PS2 the idea of this quiz is to enable people to answer by printing the page as a PDF (config. later). If there was a form version where the answers could be submited as well that would be great.

Last edited by cantthinkofanic; 02-07-2009 at 04:10 PM..
cantthinkofanic is offline   Reply With Quote
Old 02-08-2009, 07:10 AM   PM User | #7
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,292
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
Please put the obfuscated one back up. You could also try using this.

http://javascript.about.com/library/blformat.htm
__________________
||||If you are getting paid to do a job, don't ask for help on it!||||
_Aerospace_Eng_ is offline   Reply With Quote
Old 02-08-2009, 08:59 AM   PM User | #8
cantthinkofanic
New Coder

 
Join Date: Jan 2008
Location: Lulworth, Dorset, England
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
cantthinkofanic is an unknown quantity at this point
OK, I have put the old one back.
cantthinkofanic is offline   Reply With Quote
Old 02-08-2009, 05:07 PM   PM User | #9
_Aerospace_Eng_
Supreme Master coder!


 
_Aerospace_Eng_'s Avatar
 
Join Date: Dec 2004
Location: In a place far, far away...
Posts: 19,292
Thanks: 2
Thanked 1,044 Times in 1,020 Posts
_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light_Aerospace_Eng_ is a glorious beacon of light
Attached are two versions of your original code from two different code formatters.
Attached Files
File Type: zip mootools.uc.zip (47.4 KB, 94 views)
__________________
||||If you are getting paid to do a job, don't ask for help on it!||||
_Aerospace_Eng_ is offline   Reply With Quote
Old 02-09-2009, 08:16 AM   PM User | #10
cantthinkofanic
New Coder

 
Join Date: Jan 2008
Location: Lulworth, Dorset, England
Posts: 20
Thanks: 0
Thanked 0 Times in 0 Posts
cantthinkofanic is an unknown quantity at this point
Thanks for your efforts I will have a good look at those.
cantthinkofanic is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:24 PM.


Advertisement
Log in to turn off these ads.