Skip to contentSkip to conversation

ssl forward / proxy question

DISCUSSION [email protected] 3 participants 6 messages Jul 25, 2003 – Jul 29, 2003

lore
Share & tools
lore
#0 lore raw

hi,

i have a NAT set up via an iptables firewall on RHAS. i have various webservers behind it (and other stuff), but now i'm required by marketing (sigh) to set up loads of SSL certificates. since apache/apache2 still requires one ip address per SSL certificate, and they mean to do lots of these, i'm wondering how to set it up in such a way that all DNS points to one external IP address such as 234.56.78.90. when the packet hits the firewall, something proxies it so that it will see the *name* address, and forward it on to a virtual IP. for example:

there are 3 domains all belonging to the same "real" IP address.

234.56.78.90 -> www.guinness.com
234.56.78.90 -> www.kicks.com
234.56.78.90 -> www.butt.com

so a user wants to go to www.guinness.com, the IP takes the packet to the fire wall/proxy/whatever, notices that it's "www.guinness.com" and and will forward t he packet on to the internal address of 10.31.1.44

user goes to www.kicks.com, and the packet goes to 10.31.1.45

www.butt.com will get forwarded to 10.31.1.46

is there something like this that is possible?

thanks!!

-\jen

#1 lore raw

Have a look at Squid proxy. The last releases admit SSL reverse proxying. If it would be capable of handling different servers your problem would be solved. You could have it inside of the firewall (but be careful with security issues).

Regards.

BGR

----- Original Message -----
From: <[email protected]>
To: <[email protected]>
Sent: Friday, July 25, 2003 2:17 AM
Subject: ssl forward / proxy question

Quoted 4 lines

hi,

i have a NAT set up via an iptables firewall on RHAS. i have various

webservers

Quoted 1 line

behind it (and other stuff), but now i'm required by marketing (sigh) to

set

Quoted 2 lines

up loads of SSL certificates. since apache/apache2 still requires one ip address per SSL certificate, and they mean to do lots of these, i'm

wondering

Quoted 1 line

how to set it up in such a way that all DNS points to one external IP

address

Quoted 1 line

such as 234.56.78.90. when the packet hits the firewall, something proxies

it

Quoted 1 line

so that it will see the *name* address, and forward it on to a virtual IP.

for

Quoted 9 lines

example:

there are 3 domains all belonging to the same "real" IP address.

234.56.78.90 -> www.guinness.com
234.56.78.90 -> www.kicks.com
234.56.78.90 -> www.butt.com

so a user wants to go to www.guinness.com, the IP takes the packet to the

fire

Quoted 1 line

wall/proxy/whatever, notices that it's "www.guinness.com" and and will

forward t

Quoted 13 lines

he packet on to the internal address of 10.31.1.44

user goes to www.kicks.com, and the packet goes to 10.31.1.45

www.butt.com will get forwarded to 10.31.1.46

is there something like this that is possible?

thanks!!

-\jen

#2 lore raw

You mean squid is going to handle the "get" requests for https?????? Meaning it's terminating SSL, sending the right cert, negotiating a session key with the client, getting the request and fetching the contents based on the "get" request from the right web server on the LAN????

Can you confirm all the above? If so, squid is a big security hole, but I'm sure it's not:

http://www.squid-cache.org/Doc/FAQ/FAQ-1.html#ss1.12

Ramin

Quoted 8 lines · Garcia Ruiz

Have a look at Squid proxy. The last releases admit SSL reverse proxying. If it would be capable of handling different servers your problem would be solved. You could have it inside of the firewall (but be careful with security issues).

Regards.

BGR

#3 lore raw

I can tell you that squid 2.5 supports reverse proxying and it works this
way: Client -> SSL -> Squid (with certificates) -> No SSL -> Internal Server. I think that HTTP proxying supports reverse proxying for more than 1 server but I don't know if it's the same for SSL. In this case your only problem is that the internal network donn't have encryption (Is it fine for you¿?). If reverse proxy works for you, you can get an extra: The load of you web servers will be much lower (you won't probably get cached SSL pages but as you know, when requesting a page there are a lot of requests -images among other- and these kind of requests can be cached and also are very heavy. The load of your servers would be also lower due to the lack of encryption-decryption inside them).

Squid 3.0 supports Client -> SSL -> Squid (with certificates) -> SSL -> Internal Server but it is in developement state (I wouldn't use in production mode).

Here you have some interesting links:
http://squid.bilkent.edu.tr/mail-archive/squid-users/200102/0714.html
http://www.squid-cache.org/mail-archive/squid-users/200303/1040.html
http://squid.visolve.com/white_papers/reverseproxy.htm

Regards,

JBGR

----- Original Message -----
From: "Ramin Dousti" <[email protected]>
To: "Garcia Ruiz" <[email protected]>
Cc: <[email protected]>; <[email protected]>
Sent: Friday, July 25, 2003 9:33 PM
Subject: Re: ssl forward / proxy question

Quoted 6 lines

You mean squid is going to handle the "get" requests for https?????? Meaning it's terminating SSL, sending the right cert, negotiating a session key with the client, getting the request and fetching the contents based on the "get" request from the right web server on the LAN????

Quoted 10 lines

Can you confirm all the above? If so, squid is a big security hole, but I'm sure it's not:

http://www.squid-cache.org/Doc/FAQ/FAQ-1.html#ss1.12

Ramin

Quoted 1 line · Garcia Ruiz

Have a look at Squid proxy. The last releases admit SSL reverse

proxying. If

Quoted 8 lines
Quoted 7 lines

it would be capable of handling different servers your problem would be solved. You could have it inside of the firewall (but be careful with security issues).

Regards.

BGR

#4 lore raw

THe original poster has three web servers with three certs (I think). The reverse proxy you are explaining below can only hold one cert (this is the nature of SSL).

Ramin

Quoted 60 lines · Garcia Ruiz

I can tell you that squid 2.5 supports reverse proxying and it works this
way: Client -> SSL -> Squid (with certificates) -> No SSL -> Internal Server. I think that HTTP proxying supports reverse proxying for more than 1 server but I don't know if it's the same for SSL. In this case your only problem is that the internal network donn't have encryption (Is it fine for you¿?). If reverse proxy works for you, you can get an extra: The load of you web servers will be much lower (you won't probably get cached SSL pages but as you know, when requesting a page there are a lot of requests -images among other- and these kind of requests can be cached and also are very heavy. The load of your servers would be also lower due to the lack of encryption-decryption inside them).

Squid 3.0 supports Client -> SSL -> Squid (with certificates) -> SSL -> Internal Server but it is in developement state (I wouldn't use in production mode).

Here you have some interesting links:
http://squid.bilkent.edu.tr/mail-archive/squid-users/200102/0714.html
http://www.squid-cache.org/mail-archive/squid-users/200303/1040.html
http://squid.visolve.com/white_papers/reverseproxy.htm

Regards,

JBGR

----- Original Message -----
From: "Ramin Dousti" <[email protected]>
To: "Garcia Ruiz" <[email protected]>
Cc: <[email protected]>; <[email protected]>
Sent: Friday, July 25, 2003 9:33 PM
Subject: Re: ssl forward / proxy question

Quoted 6 lines

You mean squid is going to handle the "get" requests for https?????? Meaning it's terminating SSL, sending the right cert, negotiating a session key with the client, getting the request and fetching the contents based on the "get" request from the right web server on the LAN????

Quoted 10 lines

Can you confirm all the above? If so, squid is a big security hole, but I'm sure it's not:

http://www.squid-cache.org/Doc/FAQ/FAQ-1.html#ss1.12

Ramin

Quoted 1 line · Garcia Ruiz

Have a look at Squid proxy. The last releases admit SSL reverse

proxying. If

Quoted 8 lines
Quoted 7 lines

it would be capable of handling different servers your problem would be solved. You could have it inside of the firewall (but be careful with security issues).

Regards.

BGR

#5 lore raw

i actually have 3 load-balanced webservers, and another lone one with virtual IPs. there are 5 SSL certificates at this time (some clients insist on having their own domain name), and it appears we are going to have more. i am trying to keep this as limited as possible, but there's only so much i can do since we only get 32 IPs from our co-lo facility.

since i have, logically, 2 different webservers, would this work (barring squid or any proxies)? $EXTERNAL_IP1 and 2 are 2 different external IPs, whereas $WEBSERVER1 and 2 are the 2 different webservers.

iptables -A FORWARD -p tcp -s $EXTERNAL_IP1 -d $WEBSERVER1 --dport 443 -j ACCEPT iptables -A FORWARD -p tcp -s $EXTERNAL_IP2 -d $WEBSERVER2 --dport 443 -j ACCEPT thanks!

-\jen

Quoted 69 lines

THe original poster has three web servers with three certs (I think). The reverse proxy you are explaining below can only hold one cert (this is the nature of SSL).

Ramin

Quoted 60 lines · Garcia Ruiz

I can tell you that squid 2.5 supports reverse proxying and it works this
way: Client -> SSL -> Squid (with certificates) -> No SSL -> Internal Server. I think that HTTP proxying supports reverse proxying for more than 1 server but I don't know if it's the same for SSL. In this case your only problem is that the internal network donn't have encryption (Is it fine for you¿?). If reverse proxy works for you, you can get an extra: The load of you web servers will be much lower (you won't probably get cached SSL pages but as you know, when requesting a page there are a lot of requests -images among other- and these kind of requests can be cached and also are very heavy. The load of your servers would be also lower due to the lack of encryption-decryption inside them).

Squid 3.0 supports Client -> SSL -> Squid (with certificates) -> SSL -> Internal Server but it is in developement state (I wouldn't use in production mode).

Here you have some interesting links:
http://squid.bilkent.edu.tr/mail-archive/squid-users/200102/0714.html
http://www.squid-cache.org/mail-archive/squid-users/200303/1040.html
http://squid.visolve.com/white_papers/reverseproxy.htm

Regards,

JBGR

----- Original Message -----
From: "Ramin Dousti" <[email protected]>
To: "Garcia Ruiz" <[email protected]>
Cc: <[email protected]>; <[email protected]>
Sent: Friday, July 25, 2003 9:33 PM
Subject: Re: ssl forward / proxy question

Quoted 6 lines

You mean squid is going to handle the "get" requests for https?????? Meaning it's terminating SSL, sending the right cert, negotiating a session key with the client, getting the request and fetching the contents based on the "get" request from the right web server on the LAN????

Quoted 10 lines

Can you confirm all the above? If so, squid is a big security hole, but I'm sure it's not:

http://www.squid-cache.org/Doc/FAQ/FAQ-1.html#ss1.12

Ramin

Quoted 1 line · Garcia Ruiz

Have a look at Squid proxy. The last releases admit SSL reverse

proxying. If

Quoted 8 lines
Quoted 7 lines

it would be capable of handling different servers your problem would be solved. You could have it inside of the firewall (but be careful with security issues).

Regards.

BGR