atom feed3 messages in ru.sysoev.nginxRe: Cookie forwarding when using reve...
FromSent OnAttachments
Liang JinMay 3, 2007 2:51 am 
Igor SysoevMay 3, 2007 5:04 am 
Liang JinMay 3, 2007 1:27 pm 
Subject:Re: Cookie forwarding when using reverse proxy
From:Liang Jin (mywe@public.gmane.org)
Date:May 3, 2007 1:27:39 pm
List:ru.sysoev.nginx

Thanks, Igor.

I was not thinking right in the early morning. I was trying to get cookies from domain2.com while accessing domain1.com

This is impossible as it will impose security issues. Anyway, I was able to use Javascript to overcome the problem I had.

Thanks again.

Best regards,

-Liang

On 5/3/07, Igor Sysoev <is-G@public.gmane.org> wrote:

On Thu, May 03, 2007 at 02:51:40AM -0700, Liang Jin wrote:

I am wondering whether it is possible to do the following trick:

Senario: Frontend nginx server is accepting requests for site A (domain1.com) and will reverse proxy to internal site B (domain2.com). There are cookies set for site A and they are not directly available to the backend site B (different domain).

So, my question is : would it be possible for nginx to forward the cookies, that are set for domain1.com, to domain2.com.

Browsers see you site as domain1.com, so they will send domain1.com cookies. nginx passes all headers inlcuding "cookie" to a backend.