From 2cf4c996f9f6c011b54301e9de31571d9068d5c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Tronel?= Date: Sun, 28 Dec 2025 18:27:09 +0100 Subject: [PATCH] Improve README. --- README.md | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/README.md b/README.md index aacc4f9..5e7d041 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,44 @@ # Purpose +I wanted to install a certificate generated by Let's encrypt on my brand new laser printer +(HP Laserjet MFJ 4302) for the integrated administration webserver. +After research on the web, I discovered + # Arguments +positional arguments: + {csr,pem} command help + csr Create CSR + pem Install certificate + +options: + -h, --help show this help message and exit + -d, --debug Activate debug. + -c, --config CONFIG_FILENAME + Configuration file. + -u, --user USERNAME Username. + -p, --password [PASSWORD] + Password. + -H, --host HOSTNAME Hostname. + -n, --no-tls-verification + Verify certificate validity. + + # How to use it ? +To obtain a CSR: +``` +./refresh-certificate.py -c ./config.ini -n -p PASSWORD csr +``` + +To obtain a PEM certificate from Let's encrypt: +``` +certbot certonly --webroot -w /var/www/letsencrypt/ --csr printer.csr +``` + +To install the PEM file on the printer: +``` +./refresh-certificate.py -c ./config.ini -n -p PASSWORD pem +``` + +