Wow Web Designs Forums Home

Search
   
Members

Calendar

Help

Home
Search by username
Not logged in - Login | Register 


JS code obfuscation...
 Moderated by: Aycan  

New Topic

Reply

Print
AuthorPost
marcelo
Member


Joined: Fri Apr 25th, 2003
Location: Buenos Aires, Capital Federal Argentina
Posts: 72
Status:  Offline
Mana: 
 Posted: Fri Apr 25th, 2003 06:56 pm

Quote

Reply
 

Here will be a (geek? nerd?) space to share experiences a examples of crypto-obfuscation applied to Javascript´d content.

Have you anything to share? :shock:

 

tom
Member
 

Joined: Sun Oct 12th, 2003
Location:  
Posts: 7
Status:  Offline
Mana: 
 Posted: Thu Oct 30th, 2003 10:42 am

Quote

Reply
I would suggest the function escape(). It makes the source unreadable (HTML, JS and CSS), however:
° You will have problems if you use % in the code
° It´s very easy to decode: JS-Function unescape()

If someone wants to use this method, he should make a file which encodes the source (big textarea - button "encode" - a simple JS-function with, for example,
document.formName.textaraName.value=escape(document.formName.textaraName.value);).
Then he should copy the encoded source, and paste it into his site with a code like this:
<script>
var src="Encoded Source";
document.write(unescape(src));
</script>

The encoded source should look similar to this example:
%3Chtml%3E%3Cbody%20bgcolor%3D%230000ff%3EExample%3Cscript%3Ealert%28%27Script%27%29%3B%3C/script%3E%3C/body%3E%3C/html%3E


 Current time is 04:40 am




Powered by WowBB 1.7 - Copyright © 2003-2006 Aycan Gulez
Page processed in 0.1371 seconds (16% database + 84% PHP). 16 queries executed.