Replace location paramter

Francis Daly francis at daoine.org
Tue Apr 13 12:29:12 UTC 2021


On Tue, Apr 13, 2021 at 05:47:07AM -0400, vybralk wrote:

Hi there,

> i have ngnix in front of java web server. My request is correctly send by
> ngnix to java web, which redirect user request to another url as user is not
> authenticated. It set location header to following value
> 
> location =
> https://login.server.com/oidc/2/auth?response_type=code&client_id=123&scope=openid+profile+email+params&redirect_uri=https://internal.server.com:8443/ords/apex_authentication.callback&state=123123123123asdfsadfasdf
> 
> but the server name isn't correct as it is accessible under different name
> from internet. I need to change it.

Does "proxy_redirect" do what you want?

http://nginx.org/r/proxy_redirect

	f
-- 
Francis Daly        francis at daoine.org


More information about the nginx mailing list