Table of Contents

TLS/SSL certificates for a server

Transport_Layer_Security (TLS, formerly called SSL) is used to encrypt and protect communication. When a webserver works with regular HTTP protocol i.e. its address starts with http but over the encrypted TLS this called HTTPS and a site address starts with https.

For all HTTPS sites a web browser shows a lock icon in an address bar.

To enable HTTPS for a website's domain we need a private key and its TLS certificate that was signed by a Certificate Authority (CA).

The OpenWrt admin site LuCI by default supports the HTTPS so you can open it with httpS://192.168.1.1/. But it's certificate is self signed and not verified by a CA so your browser will show a warning.

You can buy a TLS cert but nowadays the Let's Encrypt CA allows to sign and verify certificates for free with a certbot program that uses ACME protocol. The only problem is that the certificate will have a short period of validity and you have to configure certificate renewal.

There is few ACME clients that automates the cert issuing:

If you have already taken care of certificate automation see also Installing a publicly trusted certificate.

ACME.sh

See acme.sh

Self signed certs

See HTTPS Enable and Certificate Settings and Creation or Getting rid of LuCI HTTPS warnings.

Own Certificate Authority with PKI

See Installing and trusting a root CA certificate in a PKI

External services

You can use CloudFlare.com as a proxy that will terminate TLS and forward requests to your router with HTTP or HTTPS with a self signed certificate. Some tunnels like PageKite or localhost.run are working through HTTPS.