Injecting Set-Cookie in Reverse Proxy?

Yongtao You yongtao_you at yahoo.com
Sun Nov 20 06:28:53 UTC 2016


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 at 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 at nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx

   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20161120/f8c25fdd/attachment.html>


More information about the nginx mailing list