Re: Page links returned as http, not https or relative

2021-12-19 Thread JumpStart
Thank you again, Ben. To get my dev environment working with nginx terminating HTTPS in front of Jetty, the key things I had to change were: 1. In the nginx config add these lines, as you did below: proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_h

Re: Page links returned as http, not https or relative

2021-12-19 Thread Ben Weidig
We use Jetty, too, either behind HAProxy (production) or Nginx (dev). This is my local dev nginx setup, with the domain mapped to 127.0.0.1 via /etc/hosts map $http_x_forwarded_proto $xscheme { default $scheme; https https; } set_real_ip_from 127.0.0.1; real_ip_header X-Forwarded-For; re

Re: Page links returned as http, not https or relative

2021-12-19 Thread JumpStart
Thank you Ben, you are absolutely right. In production, our AWS ALB (application load balancer) terminates HTTPS but automatically adds the X-Forwarded-Proto header, which forwards “https” or whatever the protocol was, and Wildfly respects it if you make the configuration changes described here

Re: Page links returned as http, not https or relative

2021-12-19 Thread Ben Weidig
Hi Geoff, I can't reproduce the behavior in our setup, redirecting with relative URLs while HTTPS works fine. Which Servlet Container are you using? AFAIK it's the responsibility of the container to do the right thing and how to handle relative URLs from sendRedirect. What's in the "Location" he