/    Sign up×
Community /Pin to ProfileBookmark

encrypting the source can protect it…

have you seen Google’s gMail yet? try viewing the source inside their application.. it uses JavaScript to display the interface but encrypts the language so you can’t see how it’s done.. here is a copy of what the source code looks like:

[code]
<html><head><meta content=”text/html; charset=UTF-8″ http-equiv=”content-type”></head><script>D=(top.js&&top.js.init)?function(d){top.js.P(window,d)}:function(){};if(window==top){top.location=’/gmail?search=inbox&view=tl&start=0&init=1&zx=825599225a0991971617819337&fs=1′;}</script><script><!–
D([“v”,”825599225a099197″]
);
D([“ud”,”[email protected]”,”{“o”:”OPEN”,”/”:”SEARCH”,”\r”:”OPEN”,”k”:”PREV”,”r”:”REPLY”,”c”:”COMPOSE”,”gd”:”GO_DRAFTS”,”p”:”PREVMSG”,”gi”:”GO_INBOX”,”a”:”REPLYALL”,”!”:”SPAM”,”f”:”FORWARD”,”u”:”BACK”,”ga”:”GO_ALL”,”j”:”NEXT”,”y”:”REMOVE”,”n”:”NEXTMSG”,”gs”:”GO_STARRED”,”x”:”SELECT”,”s”:”STAR”}”]
);
D([“p”]
);
D([“ppd”,0]
);
D([“i”,0]
);
D([“qu”,”0 MB”,”1000 MB”,”0%”,”#006633″]
);
D([“ft”,”Visit <span style=”color:#0000CC;text-decoration:underline;cursor:pointer;cursor:hand;white-space:nowrap” id=”prf_g”>settings</span> to save time with <b>keyboard shortcuts</b>!”]
);
D([“ds”,0,0,0,0,0,0,0]
);
D([“ct”,[]
]
);
D([“ts”,0,50,1,0,”Inbox”,”ffb259bbeb”,1,””]
);
D([“t”,[“ff2ca1800ed5ccf”,0,0,”Sep 23″,”<span id=’[email protected]’>Gmail Team</span>”,”<b>&raquo;</b>&nbsp;”,”Gmail is different. Here’s what you need to know.”,”First off, welcome. And thanks for agreeing to help us test Gmail. By now you probably know the &hellip;”,[]
,””,”ff2ca1800ed5ccf”,0]
]
);
D([“te”]);

//–></script><script>var fp=’ff7025b400fa2171′;</script><script>var loaded=true;D([‘e’]);</script><script>try{top.js.L(window,249,’4f30a66ade’);}catch(e){}</script>
[/code]

as for the algorithm which performs the encryption… well it’s a Google technology, maybe we’ll see it on sourceforge someday… Just saying it can be done : )

to post a comment
JavaScript

9 Comments(s)

Copy linkTweet thisAlerts:
@sciguyryanOct 19.2004 — Its still not REALLY protected, if someoen found the JS source file they could easily break the coding.


RyanJ
Copy linkTweet thisAlerts:
@benipsenauthorOct 19.2004 — try requesting the "top.js" file... i'd say it's "really" protected... unless you have a clever way of requesting documents on the server that I don't
Copy linkTweet thisAlerts:
@sciguyryanOct 19.2004 — Well, I found the file in my temporary internet files ?


RyanJ
Copy linkTweet thisAlerts:
@benipsenauthorOct 19.2004 — well done! should have thouht of the cache... everything was intact?
Copy linkTweet thisAlerts:
@sciguyryanOct 19.2004 — I've got most of the stuff.


RyanJ
Copy linkTweet thisAlerts:
@Reli4ntOct 19.2004 — You can almost always find content developers "attempt" to pretect in there.

My question is, does anyone know how to circumvent this?
Copy linkTweet thisAlerts:
@sciguyryanOct 19.2004 — [i]Originally posted by Reli4nt [/i]

[B]You can almost always find content developers "attempt" to pretect in there.



My question is, does anyone know how to circumvent this? [/B]
[/QUOTE]


Exactly what do you want to over-ride?

RyanJ
Copy linkTweet thisAlerts:
@Reli4ntOct 19.2004 — Is it possible to keep certain content from the cache, e.g. images, flash, css, etc.

Mind you I personally think it should all be freely available, but clients can get touchy about their copyrighted material.
Copy linkTweet thisAlerts:
@jbotOct 20.2004 — [i]Originally posted by Reli4nt [/i]

[B]Is it possible to keep certain content from the cache, e.g. images, flash, css, etc.[/B][/QUOTE]


no, everything get's cached at runtime. you can use certain metatags to delete the material from the cache post-session, but it will always be there at some time - you can't avoid it.

question: did you not read Fredmv's sticky about protecting source code?
×

Success!

Help @benipsen spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.25,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...