Blame SOURCES/0016-Issue-4460-BUG-add-machine-name-to-subject-alt-names.patch

be9751
From 3007700a659ede03085f5390153cce483ce987a1 Mon Sep 17 00:00:00 2001
be9751
From: Firstyear <william@blackhats.net.au>
be9751
Date: Fri, 4 Dec 2020 10:14:33 +1000
be9751
Subject: [PATCH] Issue 4460 - BUG - add machine name to subject alt names in
be9751
 SSCA (#4472)
be9751
be9751
Bug Description: During SSCA creation, the server cert did not have
be9751
the machine name, which meant that the cert would not work without
be9751
reqcert = never.
be9751
be9751
Fix Description: Add the machine name as an alt name during SSCA
be9751
creation. It is not guaranteed this value is correct, but it
be9751
is better than nothing.
be9751
be9751
relates: https://github.com/389ds/389-ds-base/issues/4460
be9751
be9751
Author: William Brown <william@blackhats.net.au>
be9751
be9751
Review by: mreynolds389, droideck
be9751
---
be9751
 src/lib389/lib389/instance/setup.py | 2 +-
be9751
 1 file changed, 1 insertion(+), 1 deletion(-)
be9751
be9751
diff --git a/src/lib389/lib389/instance/setup.py b/src/lib389/lib389/instance/setup.py
be9751
index 7d42ba292..e46f2d1e5 100644
be9751
--- a/src/lib389/lib389/instance/setup.py
be9751
+++ b/src/lib389/lib389/instance/setup.py
be9751
@@ -887,7 +887,7 @@ class SetupDs(object):
be9751
                         tlsdb_inst = NssSsl(dbpath=os.path.join(etc_dirsrv_path, dir))
be9751
                         tlsdb_inst.import_rsa_crt(ca)
be9751
 
be9751
-            csr = tlsdb.create_rsa_key_and_csr()
be9751
+            csr = tlsdb.create_rsa_key_and_csr(alt_names=[general['full_machine_name']])
be9751
             (ca, crt) = ssca.rsa_ca_sign_csr(csr)
be9751
             tlsdb.import_rsa_crt(ca, crt)
be9751
             if general['selinux']:
be9751
-- 
be9751
2.26.2
be9751