0

I have linked a service on my server through this reverse proxy

           var httpProxy = require('http-proxy');
           var fs = require('fs');
           
           httpProxy.createServer({
             target: {
               host: 'redacted',
               port: redacted
            },
            ssl: {
               key: fs.readFileSync(
               '/etc/letsencrypt/live/redacted/privkey.pem', 'utf8'),
               cert: fs.readFileSync(
               '/etc/letsencrypt/live/redacted/cert.pem', 'utf8')
            }
           }).listen(443);

This was necessary, because it needed https to work on all devices. The certificates were created like this:

sudo certbot certonly --standalone --agree-tos --preferred-challenges http -d  redacted

This worked perfectly fine for quite a while. But now only on mobile browsers it gives the warning that the connection is not secure, while it still works perfectly on PC and Mac. What can I do to prevent that? I am not very experienced with SSL so please don't be to hard on me if I made an obvious error.

Browser (on Android and Windows): Firefox

N00b
  • 1
  • 1

1 Answers1

0

Found the answer myself by sending this to ChatGPT. You have to also include the chain.pem in the reverse proxy. ca: fs.readFileSync('/etc/letsencrypt/live/redacted/chain.pem', 'utf8')

N00b
  • 1
  • 1