Comments on: How To: Write Custom Redirector or Rewritor Plugin For Squid in Python https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/ How Tos, Tutorials, Tips and Tricks Fri, 19 Jun 2015 15:19:58 +0000 hourly 1 https://wordpress.org/?v=4.9.4 By: Martin Taleski https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-45724 Thu, 10 Feb 2011 09:32:33 +0000 http://172.17.8.64/gofedora/?p=211#comment-45724 Hi

Do you know if it is possible to add custom http header in the new_url that we are writing in stdout.

]]>
By: Odd squid transparent redirect behavior https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-38574 Sat, 20 Nov 2010 08:49:44 +0000 http://172.17.8.64/gofedora/?p=211#comment-38574 […] The jefferson_redirect.py script is based on this script: http://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/ […]

]]>
By: Odd squid transparent redirect behavior Drija https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-38518 Fri, 19 Nov 2010 12:41:36 +0000 http://172.17.8.64/gofedora/?p=211#comment-38518 […] The jefferson_redirect.py script is based on this script: http://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/ […]

]]>
By: hafiz https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-30240 Fri, 11 Jun 2010 08:45:40 +0000 http://172.17.8.64/gofedora/?p=211#comment-30240 Hi Kulbir,
How about perl script for redirect. can you check my perl script as below:
#!/usr/bin/perl
$|=1;
while()
{
open (MYFILE, ‘status.txt’);
$input = ;
close (MYFILE);
if ($input == 1)
{ $|=1;
@X = split;
$url = $X[0];
if ($url !~ /^http://www.wow.my/)
{
$_ = $url;
s/^http://(.*)/(.*)/http://www.wow.my/2/;
print “301:$_n”;
}

}
else
{
print “$urln”
}
}
this script didn’t work if the input=1. how to make this script works and how to unbuffer the input? hope you can help me..

thanks,

]]>
By: Kulbir Saini https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-12353 Thu, 19 Nov 2009 03:30:51 +0000 http://172.17.8.64/gofedora/?p=211#comment-12353 Vivek,

I am glad you liked it 🙂

]]>
By: Vivek Yadav https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-11642 Thu, 12 Nov 2009 10:13:02 +0000 http://172.17.8.64/gofedora/?p=211#comment-11642 Dude… this short-tutorial helped me a lot…. !!
I love Python too.

Thnx…. ^_^

]]>
By: santhosh https://gofedora.com/how-to-write-custom-redirector-rewritor-plugin-squid-python/comment-page-1/#comment-291 Wed, 30 Nov -0001 00:00:00 +0000 http://172.17.8.64/gofedora/?p=211#comment-291 Hi All,

I would like to add some content to all the incoming HTML contetnt.
In squid in squid how i can do that? when i browse any webpage, i should see the content which i added in the squid. PLease help me in this regard.

]]>