Welcome! Log In Create A New Profile

Advanced

Re: Injecting Set-Cookie in Reverse Proxy?

Yongtao You via nginx
November 20, 2016 01:34AM
I was able to do this with the "headers more" module.
Thanks!Yongtao

On Saturday, November 19, 2016 4:22 PM, Yongtao You via nginx <nginx@nginx.org> wrote:


Hi,
I'm setting up a reverse proxy to my backend service as follows:
server {    location / {
        auth_request /auth;        error_page 401 =302 /login;        proxy_pass http://backend/;        add_header Set-Cookie "my=xyz"; # Can I add this in the response from backend?    }}
I would like to inject a Set-Cookie header in the response from the backend service. Is that possible? The above does not work.
Thanks.Yongtao
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Injecting Set-Cookie in Reverse Proxy?

Yongtao You via nginx November 19, 2016 07:24PM

Re: Injecting Set-Cookie in Reverse Proxy?

Yongtao You via nginx November 20, 2016 01:34AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 151
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready