[layerindex-web][PATCH 04/15] dockersetup.py: letsencrypt 2048 bit rsa


Tim Orling
 

The minimum length for an RSA pem is 2048 for the dummy cert.

Signed-off-by: Tim Orling <timothy.t.orling@intel.com>
---
dockersetup.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dockersetup.py b/dockersetup.py
index 04dec91..6a0ab67 100755
--- a/dockersetup.py
+++ b/dockersetup.py
@@ -483,7 +483,7 @@ def setup_https(hostname, http_port, https_port, letsencrypt, cert, cert_key, em
os.makedirs(local_letsencrypt_cert_dir)
keyfile = os.path.join(letsencrypt_cert_subdir, 'privkey.pem')
certfile = os.path.join(letsencrypt_cert_subdir, 'fullchain.pem')
- return_code = subprocess.call(['openssl', 'req', '-x509', '-nodes', '-newkey', 'rsa:1024', '-days', '1', '-keyout', os.path.join(local_cert_dir, keyfile), '-out', os.path.join(local_cert_dir, certfile), '-subj', '/CN=localhost'], shell=False)
+ return_code = subprocess.call(['openssl', 'req', '-x509', '-nodes', '-newkey', 'rsa:2048', '-days', '1', '-keyout', os.path.join(local_cert_dir, keyfile), '-out', os.path.join(local_cert_dir, certfile), '-subj', '/CN=localhost'], shell=False)
if return_code != 0:
print("Dummy certificate generation failed")
sys.exit(1)
--
2.32.0

Join yocto@lists.yoctoproject.org to automatically receive all group messages.