A customer needs a reverse proxy the backend of which uses different hostnames than the frontend and has 3 websites on it using namevirtualhosts (also using SSL).
So this seems to be doable with haproxy:
- on my frontend, differentiate between the different hostnames via SNI
- the real servers use different custom SNI names, so the backend can differentiate
- a Host header is set for the backend with abovementioned SNI names, or else the backend doesn't switch to the right website
- location headers in the response are rewritten to my frontend names
In apache, one would do this using ProxyPass / ProxyPassReverse, while I didn't test it, this seems fairly simple.
Now correct me if I'm wrong, but this doesn't seem possible with nginx on opnsense, not having the UI elements to specify a custom host header for an upstream?