Search squid archive

Re: Rewrite http to https for owa.

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

 



Dwyer, Simon wrote:
> One last step to have it fully working is to rewrite address's coming in on
> http to https.  This is for OWA.  I have tried to use squirm and have some
> success.  What I need to do is redirect http://mail.domainname.com/  to
> https://mail.domainname/com/owa.  For all reverse proxy requests.  Is there
> an easier way to do this?  I have googled it without much success.
>   

Here's how I do exactly that.  In squid.conf:

    url_rewrite_program /usr/local/bin/rewrite-http

and then:

% cat /usr/local/bin/rewrite-http
#!/usr/bin/perl
#
# URL rewriter for squid to convert HTTP requests to HTTPS.
# Return an HTTP permanent redirect back to the browser.
# http://wiki.squid-cache.org/SquidFaq/SquidRedirectors
#
$| = 1;
while (<>) {
        s/^http:/301:https:/;           # replace "http" with "https"
        print;
}


-- 
CONFIDENTIALITY NOTICE: This e-mail message,including any
attachments,is for the sole use of the intended recipient(s)
and may contain confidential and privileged information. Any
unauthorized review, use, disclosure or distribution is 
prohibited. If you are not the intended recipient,please
contact the sender by reply e-mail and destroy all copies
of the original message.

begin:vcard
fn:Ben Hollingsworth
n:Hollingsworth;Ben
org:BryanLGH Medical Center;Information Technology
adr:;;1600 S. 48th St.;Lincoln;NE;68506-1275;USA
email;internet:ben.hollingsworth@xxxxxxxxxxxx
title:Systems Programmer
tel;work:402-481-8582
tel;fax:402-481-8354
url:http://www.bryanlgh.org
version:2.1
end:vcard


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

  Powered by Linux