Search squid archive

Re: rewriter/redirector question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Le mardi 11 août 2009 12:33:26, Leonardo Carneiro a écrit :
> Hello everyone,
>
> Sometime ago i blocked some popular social network sites. However, some
> users manage to access those sites using sites like atunnel and others.
> Since blocking every single proxy site on the web is a invencible task,
> i chose to teach the users a little funny lesson, like redirecting then
> to durty porn site in front of the others when they tried to access a
> known forbidden site, before sending then serious notifications, and
> stuff like that.
>
> Researching about how to do that, i just created a acl selecting those
> sites, and my failure url is a html file with a javascript code that
> sends to another site:
>
>     <!--
>     To change this template, choose Tools | Templates
>     and open the template in the editor.
>     -->
>     <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
>     <html>
>       <head>
>         <title></title>
>         <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
>             <script>
>                 window.location = "<some_site>";
>                     </script>
>       </head>
>       <body>
>
>       </body>
>     </html>
>
> Since rewriter/redirector looked to complicated to me at the time, and
> this was a very efficient solution, i leaved in that way.
>
> The question is: what i'm missing using a "dumb" solucion like this one
> instead of the rewriter/redirector?
you should write you own redirector

I wrote on in perl:
http://pastebin.com/f42ca3ef4

read code and enjoy



[Index of Archives]     [Linux Audio Users]     [Samba]     [Big List of Linux Books]     [Linux USB]     [Yosemite News]

  Powered by Linux