> I’m using Squid 2.5-STABLE14 with SSL support. I need to rewrite every url > with “http://...“; request to “https://...”; so I use this script at the > redirect_program line: Old version... ^_^ > #!/usr/bin/perl > > $|=1; > > while (<>) > { > @X = split; > $url = $X[0]; > > if ($url =~ /^http:\/\//) > { > $url =~ s/http/https/; > print "301:$url\n"; > exit; > } > else > { > print "$url\n"; > exit; > } > } I think you should remove the 2 exits... > The problem is that access.log shows every GET with > “http://...”;, even after be matched with script, and makes an infinite loop > requests (the script redirects to https but the Squid take it as http and > make the redirection again). What I can do? How can I make the “http” to > “https” to work fine? What is your acl for the rewrite? Maybe that would prevent the loops... url_rewrite_access allow !SSL_ports JD