Sphere
Log in Join
☆ 7

nginx ssl chain okay on desktop but android rejects it

Cert from Let's Encrypt via certbot 2.11, nginx 1.26 on Debian 12. SSL Labs gives an A but Android Chrome says NET::ERR_CERT_AUTHORITY_INVALID while desktop browsers are fine. My fullchain.pem has leaf plus R3 intermediate, no ISRG Root X1. I tried concatenating ISRG Root X1 manually onto fullchain.pem and reloading, same result. openssl s_client -connect example.com:443 -showcerts shows 2 certs. Do I need the root in there or is this a chain ordering thing?

⚑ Report

3 replies

☆ 3
C cache32 ·2026-10-16#1

Don't add the root, browsers won't use a root you serve, it has to be trusted locally already. The usual cause is serving the wrong file. Check that ssl_certificate points to fullchain.pem and not cert.pem. Also older Android trusts the DST Root CA X3 cross-sign which expired, so on an old device you can hit that instead of a chain problem. What does your ssl_certificate line actually say?

⚑ Report
☆ 0
I inode ·2026-10-20#2

You were right about ssl_certificate, I had cert.pem in one server block left over from a config I copied months ago. Switched it to fullchain.pem and Android is happy now. The ISRG Root X1 concatenation wasn't needed so I removed it. For what it's worth the failing device was Android 7, so the DST X3 expiry theory might also have been in play. Fixed either way.

⚑ Report
☆ 0
P plastic17 ·2026-10-30#3

Good catch. You can verify the chain depth with openssl s_client -showcerts piped to a grep for the depth lines, should show exactly two, leaf and intermediate. ssl_stapling on with ssl_trusted_certificate pointing at fullchain helps some clients but the real fix was always the right file in ssl_certificate. Worth checking every server block next time.

⚑ Report
Log in to reply.