Re: Dynamic Javascript Obfuscator & compression Apache module?
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.javascript archive

Re: Dynamic Javascript Obfuscator & compression Apache module?

From: Roman Ziak <romanziak@yahoo.ca>
Date: Fri Mar 31 2006 - 17:57:35 CEST

RobG wrote:
> Chetan Patil wrote:
> > I would like to obfuscate and compress (remove comments, newlines etc)
> > my javascript files / ajax code. Is there a module that will do this on
> > the
> > fly with some level of caching?
>
> There seems little point in doing it on the fly - do it once, test it, then
> publish. Why compress the JS file every single time? It will likely cause
> the file to be not cached on the client.

Same as for gzip compression on the fly - the server may keep the cache
but I think it does not keep gzip-ed versions of pages on persistent
storage. But different servers may act differently too.

>
> Forget obfuscation, minification is good:
>
> <URL:http://www.crockford.com/javascript/jsmin.html>

There is great compressor from Dean Edwards

  http://dean.edwards.name/packer/

But again, the results may vary especially when using the mentioned
on-the-fly gzip compression.

As for the original poster - you do not need Apache module, the job can
be done by server script fetching the original JS file and obfuscating
(or even caching the obfuscated version).

  Roman
>
>
> --
> Rob
Received on Mon May 1 04:34:21 2006