OPNsense Forum

English Forums => Web Proxy Filtering and Caching => Topic started by: Brashquido on May 24, 2025, 10:22:47 AM

Title: NGNIX Upstream TLS Verification?
Post by: Brashquido on May 24, 2025, 10:22:47 AM
Hi All,

Looking to use NGINX as a WAF for my selfhosted Wordpress site (running in a Turnkey LXC container) and am completely lost in regard to getting TLS to work all the way through to my internal server without unchecking Configuration>Upstream>TLS:Verify Certificate option which is also accompanied with the text, "
Don't turn it off unless you really know what you are doing! Never do it because a random website tells you to do."

What I have done so far on my Opnsense Router;

Seems to work fine on HTTP, however HTTPS only seems to work with the above-mentioned TLS: Verify Certificate option disabled. NGNIX HTTPS Error logs have entries including text such as 
SSL_do_handshake() failed (SSL: error:0A00010B:SSL routines::wrong version number) while SSL handshaking to upstream
Is this referring to the Apache web server my Wordpress LXC is using. Are there certain upstream Apache configuration items that have to be set for this to work? What are the implications of having this TLS: Verifiy Certificate option turned off?
 
Title: Re: NGNIX Upstream TLS Verification?
Post by: RamSense on May 24, 2025, 09:46:16 PM
I'm not using Turnkey LXC Container, but docker. I think your container has no SSL certificate and gives nginx the error "SSL routines::wrong version number) while SSL handshaking to upstream"

when you set upstream - upstream Enable TLS (HTTPS) [to disable, not selected]

(and your https - http server - [your servername] - HTTPS Only [enabled] )

you should get nginx to handle the ssl and get an https connection to your container.