]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
Seed RNG when starting up sshd-auth.
authorDarren Tucker <dtucker@dtucker.net>
Thu, 17 Oct 2024 09:50:29 +0000 (20:50 +1100)
committerDarren Tucker <dtucker@dtucker.net>
Thu, 17 Oct 2024 09:50:29 +0000 (20:50 +1100)
Makes builds configured --without-openssl work again since otherwise
the first use of the RNG comes after the sandbox init and it can't
open /dev/random.

sshd-auth.c

index 986052cd3408f751a31dbd6c91c6fe0219781fd8..bb694dd4ace6f2841f24c46cf1586aef70b185c5 100644 (file)
@@ -472,6 +472,8 @@ main(int ac, char **av)
                saved_argv[i] = xstrdup(av[i]);
        saved_argv[i] = NULL;
 
+       seed_rng();
+
 #ifndef HAVE_SETPROCTITLE
        /* Prepare for later setproctitle emulation */
        compat_init_setproctitle(ac, av);