summaryrefslogtreecommitdiffstats
path: root/meta/recipes-connectivity/openssh
diff options
context:
space:
mode:
authorXiangyu Chen <xiangyu.chen@eng.windriver.com>2022-12-09 15:05:38 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-12-09 13:18:41 +0000
commitcc63d80b9433e2eec2c9e33808e676956d6906ba (patch)
treee34bf18f2d07bf33b0d9bf4dab2e0a2a5e3b6b35 /meta/recipes-connectivity/openssh
parent94c019d9c0a1e09fcdc7f971232f467546f36ee4 (diff)
downloadpoky-cc63d80b9433e2eec2c9e33808e676956d6906ba.tar.gz
openssh: remove RRECOMMENDS to rng-tools for sshd package
It appears that rngd is not needed as of linux-5.6 and later[1] and should not be installed by default since the purpose of rngd is to provide additional trusted sources of entropy. We did some testing on real hardware, the result seems to support that we no longer need rngd by default on kernel v5.6 and later. Testing result as below: 1. observing the crng init stage. the "random: crng init done" always available before fs being mounted. 2. generating random number without rngd. testing command: dd if=/dev/random of=/dev/null status=progress on Marvell CN96xx RDB board, speed almost 20.4 MB/s without block on NXP i.mx6q board, speed almost 31.9 MB/s without block on qemu x86-64, speed almost 2.6MB/s without block 3. using rngtest command without rngd testing command: rngtest -c 1000 </dev/random on Marvell CN96xx RDB board: rngtest: input channel speed: (min=4.340; avg=135.364; max=146.719)Mibits/s rngtest: FIPS tests speed: (min=8.197; avg=69.020; max=72.800)Mibits/s rngtest: Program run time: 418771 microseconds on NXP i.mx6q board: rngtest: input channel speed: (min=96.820; avg=326.769; max=340.598)Mibits/s rngtest: FIPS tests speed: (min=15.090; avg=37.543; max=40.324)Mibits/s rngtest: Program run time: 570229 microseconds on qemu x86-64: rngtest: input channel speed: (min=37.769; avg=101.136; max=136.239)Mibits/s rngtest: FIPS tests speed: (min=10.288; avg=30.682; max=40.155)Mibits/s rngtest: Program run time: 836800 microseconds 4. observing sshd service. using "systemctl disable rng-tools" disable service and reboot system. system boot up normal, sshd service also start in normal time without block. Reference: [1] https://github.com/torvalds/linux/commit/30c08efec8884fb106b8e57094baa51bb4c44e32 (From OE-Core rev: 868dfb46d96a27ec9041cb902fb769330277257d) Signed-off-by: Xiangyu Chen <xiangyu.chen@windriver.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-connectivity/openssh')
-rw-r--r--meta/recipes-connectivity/openssh/openssh_9.1p1.bb9
1 files changed, 1 insertions, 8 deletions
diff --git a/meta/recipes-connectivity/openssh/openssh_9.1p1.bb b/meta/recipes-connectivity/openssh/openssh_9.1p1.bb
index 85f97b1bbb..23ae8d5b0c 100644
--- a/meta/recipes-connectivity/openssh/openssh_9.1p1.bb
+++ b/meta/recipes-connectivity/openssh/openssh_9.1p1.bb
@@ -52,15 +52,12 @@ SYSTEMD_SERVICE:${PN}-sshd = "sshd.socket"
52 52
53inherit autotools-brokensep ptest 53inherit autotools-brokensep ptest
54 54
55PACKAGECONFIG ??= "rng-tools" 55PACKAGECONFIG ??= ""
56PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5" 56PACKAGECONFIG[kerberos] = "--with-kerberos5,--without-kerberos5,krb5"
57PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns" 57PACKAGECONFIG[ldns] = "--with-ldns,--without-ldns,ldns"
58PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit" 58PACKAGECONFIG[libedit] = "--with-libedit,--without-libedit,libedit"
59PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat" 59PACKAGECONFIG[manpages] = "--with-mantype=man,--with-mantype=cat"
60 60
61# Add RRECOMMENDS to rng-tools for sshd package
62PACKAGECONFIG[rng-tools] = ""
63
64EXTRA_AUTORECONF += "--exclude=aclocal" 61EXTRA_AUTORECONF += "--exclude=aclocal"
65 62
66# login path is hardcoded in sshd 63# login path is hardcoded in sshd
@@ -160,10 +157,6 @@ FILES:${PN}-keygen = "${bindir}/ssh-keygen"
160 157
161RDEPENDS:${PN} += "${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-keygen ${PN}-sftp-server" 158RDEPENDS:${PN} += "${PN}-scp ${PN}-ssh ${PN}-sshd ${PN}-keygen ${PN}-sftp-server"
162RDEPENDS:${PN}-sshd += "${PN}-keygen ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-keyinit pam-plugin-loginuid', '', d)}" 159RDEPENDS:${PN}-sshd += "${PN}-keygen ${@bb.utils.contains('DISTRO_FEATURES', 'pam', 'pam-plugin-keyinit pam-plugin-loginuid', '', d)}"
163RRECOMMENDS:${PN}-sshd:append:class-target = "\
164 ${@bb.utils.filter('PACKAGECONFIG', 'rng-tools', d)} \
165"
166
167# gdb would make attach-ptrace test pass rather than skip but not worth the build dependencies 160# gdb would make attach-ptrace test pass rather than skip but not worth the build dependencies
168RDEPENDS:${PN}-ptest += "${PN}-sftp ${PN}-misc ${PN}-sftp-server make sed sudo coreutils" 161RDEPENDS:${PN}-ptest += "${PN}-sftp ${PN}-misc ${PN}-sftp-server make sed sudo coreutils"
169 162