[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#959726: [PATCH] Check sshd_config.d/* for HostKey in postinst



If you can safely assume that /etc/ssh/sshd_config.d exists you can simply add
it to the list of files scanned for HostKey.

---
 debian/openssh-server.postinst | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/debian/openssh-server.postinst b/debian/openssh-server.postinst
index f45f5851c..aa4bee899 100644
--- a/debian/openssh-server.postinst
+++ b/debian/openssh-server.postinst
@@ -18,7 +18,7 @@ get_config_option() {
 	perl -lne '
 		s/[[:space:]]+/ /g; s/[[:space:]]+$//;
 		print if s/^[[:space:]]*'"$option"'[[:space:]=]+//i' \
-	   /etc/ssh/sshd_config
+	   /etc/ssh/sshd_config /etc/ssh/sshd_config.d/*
 }
 
 
-- 
2.29.2


Reply to: