RE: Redirecting request from HTTP to HTTPS

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

 



Thanks Krist, for looking in to this and providing a brief description.

Yes, you understood the problem correctly and I was wrong by asking to
remove the proxy. I cannot get rid off the proxy server.

Have your frontend forward both http and https requests to the http
port on your backend. This config also makes it possible to run your
frontend on the standard http and https ports.

By using the rewrite engine rule and the proxy settings specified below,
I am able to receive the entire http request to https. Please have a
look and let me know, I understood you correctly or not this time.

LoadModule proxy_module modules/mod_proxy.so
ProxyRequests Off
<Proxy *>
Order deny,allow
Allow from all
</Proxy>
ProxyPass /hsbc http://localhost:8082/hsbc

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


Regards
Tarun

-----Original Message-----
From: Krist van Besien [mailto:krist.vanbesien@xxxxxxxxx] 
Sent: Monday, April 20, 2009 8:34 PM
To: users@xxxxxxxxxxxxxxxx
Subject: Re:  Redirecting request from HTTP to HTTPS

On Mon, Apr 20, 2009 at 1:50 PM, Tarun Narang
<Tarun.Narang@xxxxxxxxxxxxx> wrote:
> Hi Krist
>
> Thanks Krist, I got your point.

I have the impression you didn't.

> Now, If I remove the proxy and go for redirect. In that case, how
could
> I redirect the http request to https://localhost:4430/hsbc which
should
> redirect it to https://localhost:443/hsbc. I cannot directly redirect
> the SSL requests to Apache 1.3 because we have to use the upgraded
> modules present at apache 2.2 and not 1.3.

Redirect means:

1) Browser requests http://somehost.com/someurl.
2) Server answers with "this resource is not available here, but is
available at http://someotherhost.com/someurl
3) Broswer now requests http://someotherhost.com/someurl. previous
host is no longer involved.


Proxy means:
1) Browser requests http://somehost.com/someurl.
2) Server is configured to pass this request on to someotherhost.com
3) server gets respons from someotherhost.com
4) server returns respons to browser.

Redirecting is done with the directives that start with "Redirect".
Proxyin is done using the statements that start with "Proxy".

See the manuals.

>From your information I guess your situation is the following:
-  You have Oracle Application server, with an integrated apache 1.3,
this is your "backend".
- You have an apache 2.2 as your "frontend"

The "Frontend" needs to forward requests to the "backend". You have
this working for http, but not for https, right?

now, my first suggestion would be the following:

- If it is your intention to have the "frontend" receive all requests,
and forward then to the backend, why not just disable SSL on the
backend. Since they appear both on the same machines you really don't
need to secure communication between them.
- Have your frontend forward both http and https requests to the http
port on your backend. This config also makes it possible to run your
frontend on the standard http and https ports.

Krist

-- 
krist.vanbesien@xxxxxxxxx
krist@xxxxxxxxxxxxx
Bremgarten b. Bern, Switzerland
--
A: It reverses the normal flow of conversation.
Q: What's wrong with top-posting?
A: Top-posting.
Q: What's the biggest scourge on plain text email discussions?

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server
Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux