How to transfer a normal HTTP request to HTTPS?

Yordan Georgiev y.georgiev at gmail.com
Fri Feb 22 17:45:43 MSK 2008


May be:

location  ~ ^/shop {
                rewrite ^/(.*) https://mydomain.com/$1 permanent;
 }

On Fri, Feb 22, 2008 at 3:16 PM, Igor Sysoev <is at rambler-co.ru> wrote:

> On Fri, Feb 22, 2008 at 01:56:52PM +0100, Mustafa Toraman wrote:
>
> > Thank you for your quick reply Mr. Georgiev,
> >
> > I start my nginx configured with ssl. It is accepting HTTPS requests
> > well. Btw i have no idea about rewrite to redirect diffrent requests on
> > ports with internal rewrite.
> >
> > HTTP is accepting port 80 and SSL 443. So then i dont want to get load
> > with X2 requests with an external redirect.
> >
> > So , what is the correct rewrite code for internet transfer? Simply how
> > to work announce.php request on SSL without any external rewrite.
>
> Browser does SSL connection only if it see https:// protocol.
> If it connect to server using http:// the connection will be plain text.
>
> > Thank you!
> >
> > Yordan Georgiev wrote:
> > > Hello,
> > >
> > > First start nginx with ssl support. HINT:
> > > http://wiki.codemongers.com/NginxHttpSslModule
> > > Second, use rewrite module for redirect. HINT:
> > > http://wiki.codemongers.com/NginxHttpRewriteModule
> > >
> > > On Fri, Feb 22, 2008 at 1:51 PM, Mustafa Toraman <lists at ruby-forum.com
> >
> > > wrote:
> > >
> > >>
> > >> Simply how to work with ssl on a normal http address?
> > >>
> > >> I'm ready to pay for that or say a thanks :)
> > >>
> > >> Thank you for now!
> > >> --
> > >> Posted via http://www.ruby-forum.com/.
> > >>
> > >>
> > >
> > >
> > > --
> > > С уважение,
> > > Й. Георгиев.
> > >
> > > WEB: http://gigavolt-bg.net/
> > > Blog:  http://live.gigavolt-bg.net/
> >
> > --
> > Posted via http://www.ruby-forum.com/.
> >
>
> --
> Igor Sysoev
> http://sysoev.ru/en/
>
>


-- 
С уважение,
Й. Георгиев.

WEB: http://gigavolt-bg.net/
Blog:  http://live.gigavolt-bg.net/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://nginx.org/pipermail/nginx/attachments/20080222/31f2cc3a/attachment.html>


More information about the nginx mailing list