Key generation is still needed if someone decides not to install the
init script or uses a different init system.

Fixes: 0e0f5d31e0e0 ("[dropbear] use rc-once to create server keys")
Signed-off-by: Alexander Dahl <[email protected]>
---
 rules/dropbear.make | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/rules/dropbear.make b/rules/dropbear.make
index 536c9176a..901f50563 100644
--- a/rules/dropbear.make
+++ b/rules/dropbear.make
@@ -278,6 +278,10 @@ endif
 ifdef PTXCONF_DROPBEAR_DROPBEAR_KEY
        @$(call install_copy, dropbear, 0, 0, 0755, -, \
                /usr/bin/dropbearkey)
+
+       @$(call install_alternative, dropbear, 0, 0, 0755, 
/etc/rc.once.d/dropbear, n)
+       @$(call install_replace, dropbear, /etc/rc.once.d/dropbear, \
+               @KEYDIR@, $(PTXCONF_DROPBEAR_KEY_DIR))
 endif
 
 ifdef PTXCONF_DROPBEAR_DROPBEAR_CONVERT
@@ -300,9 +304,6 @@ ifdef PTXCONF_DROPBEAR_STARTSCRIPT
        @$(call install_alternative, dropbear, 0, 0, 0755, 
/etc/init.d/dropbear, n)
        @$(call install_replace, dropbear, /etc/init.d/dropbear, \
                @KEYDIR@, $(PTXCONF_DROPBEAR_KEY_DIR))
-       @$(call install_alternative, dropbear, 0, 0, 0755, 
/etc/rc.once.d/dropbear, n)
-       @$(call install_replace, dropbear, /etc/rc.once.d/dropbear, \
-               @KEYDIR@, $(PTXCONF_DROPBEAR_KEY_DIR))
 
 ifneq ($(call remove_quotes,$(PTXCONF_DROPBEAR_BBINIT_LINK)),)
        @$(call install_link, dropbear, \
-- 
2.30.2


_______________________________________________
ptxdist mailing list
[email protected]
To unsubscribe, send a mail with subject "unsubscribe" to 
[email protected]

Reply via email to