[Building Sakai] Proxying through Apache

chuot con chuot_con1999 at yahoo.com
Thu Apr 8 03:26:01 PDT 2010


Hi Martin,

My server do not support mod_proxy_ajp, so I set up with both mod_proxy and mod_jk but not successful.
When I access to the address http://localhost/portal, the web server always redirects to the address https://localhost:8443/portal but not https://localhost/portal. 
Please help me resolving this problem.

server.xml:

    <Connector port="8443" maxHttpHeaderSize="8192"
               maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
               enableLookups="false" disableUploadTimeout="true"
               acceptCount="100" scheme="https" secure="true"
               clientAuth="false" sslProtocol="TLS" URIEncoding="UTF-8" />

    <Connector port="8009" 
               enableLookups="false" redirectPort="8443" protocol="AJP/1.3" URIEncoding="UTF-8" />

sakai.properties:
serverUrl=http://localhost:8080


Thanks for your helping.
Regards.
Thinh

--- On Thu, 4/8/10, Martin B. Smith <smithmb at ufl.edu> wrote:

From: Martin B. Smith <smithmb at ufl.edu>
Subject: Re: [Building Sakai] Proxying through Apache
To: "chuot con" <chuot_con1999 at yahoo.com>
Cc: sakai-dev at collab.sakaiproject.org
Date: Thursday, April 8, 2010, 2:17 AM

On 04/07/2010 01:16 PM, chuot con wrote:
> Hi Martin,
> 
> I included this line into my server.xml file:
> 
> <Connector protocol="AJP/1.3" debug="0" redirectPort="443"
>                enableLookups="false" port="8009" maxProcessors="1024"
>                minProcessors="20" acceptCount="10"
>                connectionTimeout="20000"
>                URIEncoding="UTF-8"
>                tomcatAuthentication="false"
>                scheme="https" secure="true"
>                slProtocol="TLS"
>                proxyName="localhost"
>                proxyPort="443"
>                 />
> It works with SSL but not correctly. I can access by address:
> http://localhost/portal.
> When I login into sakai, the web browser redirect to
> https://localhost/portal.
> It not secure. Because, I can capture a package that obtain information
> of user (username + password). Web server do not automate redirect to
> https://localhost/portal. It only automate redirect to
> https://localhost/portal when I login into sakai.
> 
> How should I do to web server always redirect to
> https://localhost/portal when I access to http://localhost/portal ?
> 
> Regards.
> Thinh.
> Rea


Hi again,

We use mod_rewrite (in the Apache virtual host configuration file) to
force all non-SSL requests to get redirected:

  RewriteEngine On
  RewriteCond %{HTTPS} !=on
  RewriteRule ^(.*) https://%{SERVER_NAME}$1 [R,L]

Hope that helps,
-- 
Martin B. Smith
smithmb at ufl.edu - (352) 273-1374
CNS/Open Systems Group
University of Florida




      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20100408/5af110ae/attachment.html 


More information about the sakai-dev mailing list