From: Michal Suchanek Date: 2006-08-16T02:51:20+09:00 Subject: Re: webrick, ssl and non-ssl on the same port On 8/10/06, Francis Cianfrocca wrote: > On 8/10/06, Pavel Smerk wrote: > > Hello all, > > > > I have sslized webrick server, but I'd like to have some parts of server > > accessible even without ssl. I've tried to search web and groups, but > > I haven't found anything --- any suggestions, how to get ssl and nonssl > > servlets on the same port? > > > > Thanks in advance, > > > > P. > > > > > > what I think you're proposing is not usually done for web sites. Do > you want to open a server port and have it automatically detect an > SSL/TLS client-hello so you can do an SSL handshake if present, and > simply serve the connection with no encryption otherwise? If you do > that, then how do you ensure that people will use encryption on the > sensitive pages? It's a lot of additional logic to make that happen. > Just use two ports. The page is either available through http or https - these are two different URLs. So the request should get to the right type of service. Of course it is simpler to use two ports (and it is the default anyway, you would have to use a port number with either http or https to get them use the same port). But it is an interesting idea nontheless. Thanks Michal