[onerng talk] OneRNG does not work on Ubunti 21.10

Jim Cheetham jim at gonzul.net
Thu Nov 4 08:41:45 GMT 2021


Hi, thanks for that detailed report.

At the moment you are quite right; the OneRNG helper software does not work
with recent distributions of Linux correctly. There have been a lot of
changes in both the kernel's random code, and in the userspace tools - the
latter due to distributions preferring systemd options to existing daemons.

I'm not the expert in the userspace tools, so I'll have to do another dive
into the current state of affairs; but my understanding is that /dev/random
no longer works the way it used to - it will not make extra calls to
hardware entropy sources when under heavy use, and instead will continue to
deliver data from a software PRNG; and therefore even if all the other
software is set up correctly, you won't see any change in the OneRNG LEDs.

However, you can still collect data directly from OneRNG - have a look at
the manual instructions http://moonbaseotago.com/onerng/#verify for details.

On Wed, Nov 3, 2021 at 10:31 AM Denis BEURIVE <
p-360aPUfxhAEAqi5fg2TPVn at lists.onerng.info> wrote:

> OneRNG <http://lists.onerng.info>
>
> [image: Photo of Denis BEURIVE]
> <http://lists.onerng.info/p/360aPUfxhAEAqi5fg2TPVn>
> *OneRNG does not work on Ubunti 21.10*
> <http://lists.onerng.info/r/topic/4FHCQZ3tNY9pOsjtwxXi7Q>
> by *Denis BEURIVE* <http://lists.onerng.info/p/360aPUfxhAEAqi5fg2TPVn>
> in *OneRNG Talk* <http://lists.onerng.info/groups/onerng-talk>
> ------------------------------
> Hello,
>
> First of all: you can find a well-formatted question at this URL:
>
> https://*github.com*​/denis​-beurive​/onerng​-notes
> <https://github.com/denis-beurive/onerng-notes>
>
> It seems that it is not possible to format text on this forum (which makes
> reading pretty difficult). I strongly suggest that you read the question on
> the GitHub link above.
>
> So, this is the question :
>
> I installed the required software on Ubuntu 21.10 ("`impish`").
>
>
> $ uname -a
> Linux labo 5.13.0-20-generic #20-Ubuntu SMP Fri Oct 15 14:21:35 UTC 2021
> x86_64 x86_64 x86_64 GNU/Linux
>
>
> $ lsb_release -a
> No LSB modules are available.
> Distributor ID: Ubuntu
> Description: Ubuntu 21.10
> Release: 21.10
> Codename: impish
>
>
> The complete installation procedure is given below. Please note that the
> official procedure does not work for the version of Ubuntu I use.
>
> The command to reaload the rules is "sudo udevadm control --reload-rules".
>
> Note: I install "python-gpg" using "pip", within a virtual environment.
>
>
> sudo apt-get install rng-tools at openssl
> wget -O onerng_3.6.orig.tar.gz https://*github.com*
> ​/OneRNG​/onerng​.github​.io​/blob​/master​/sw​/onerng​_3​.6​.orig​.tar​.gz​?raw​=true
> <https://github.com/OneRNG/onerng.github.io/blob/master/sw/onerng_3.6.orig.tar.gz?raw=true>
> md5sum onerng_3.6.orig.tar.gz
> tar zxvf onerng_3.6.orig.tar.gz
> cd onerng_3.6.orig
> sudo make install
> sudo udevadm control --reload-rules; echo $?
>
>
> I have read threads on this forum, so I made some tests:
>
>
> $ mkdir onerng && cd onerng
> $ virtualenv --python=python3.9.7 venv
> $ source venv/bin/activate
> (venv) $ python --version
> Python 3.9.7
> (venv) $ pip install python-gnupg
> Requirement already satisfied: python-gnupg in
> ./venv/lib/python3.9/site-packages (0.4.7)
> (venv) $ sudo /sbin/onerng.sh daemon ttyACM0 ; echo $?
> nohup: redirection de la sortie d'erreur standard vers la sortie standard
> 0
>
>
> OK, it seems that everything is fine:
>
>
> (venv) $ sudo dmesg
> [15003.792514] perf: interrupt took too long (4995 > 4968), lowering
> kernel.perf_event_max_sample_rate to 40000
> [15319.701445] audit: type=1400 audit(1635883955.014:66):
> apparmor="STATUS" operation="profile_load" profile="unconfined"
> name="/usr/sbin/haveged" pid=11589 comm="apparmor_parser"
> [15532.082788] usb 2-1.6: USB disconnect, device number 4
> [15534.823818] usb 2-1.5: new full-speed USB device number 5 using ehci-pci
> [15534.937052] usb 2-1.5: New USB device found, idVendor=1d50,
> idProduct=6086, bcdDevice= 0.09
> [15534.937072] usb 2-1.5: New USB device strings: Mfr=1, Product=3,
> SerialNumber=3
> [15534.937079] usb 2-1.5: Product: 00
> [15534.937083] usb 2-1.5: Manufacturer: Moonbase Otago http://
> *www.moonbaseotago.com*​/random <http://www.moonbaseotago.com/random>
> [15534.937088] usb 2-1.5: SerialNumber: 00
> [15534.939180] cdc_acm 2-1.5:1.0: ttyACM0: USB ACM device
> [15797.400014] userif-3: sent link down event.
> [15797.400034] userif-3: sent link up event.
> [15798.006996] userif-3: sent link down event.
> [15798.007014] userif-3: sent link up event.
>
>
> However:
>
>
> (venv) $ systemctl restart rng-tools
> (venv) $ systemctl status rng-tools
> ● rng-tools.service - Add entropy to /dev/random 's pool a hardware RNG
> Loaded: loaded (/lib/systemd/system/rng-tools.service; enabled; vendor
> preset: enabled)
> Active: active (running) since Tue 2021-11-02 22:16:25 CET; 2s ago
> Main PID: 19595 (rngd)
> Tasks: 1 (limit: 18478)
> Memory: 276.0K
> CPU: 10ms
> CGroup: /system.slice/rng-tools.service
> └─19595 /usr/sbin/rngd -r /dev/hwrng -f
>
> nov. 02 22:16:25 labo systemd[1]: Started Add entropy to /dev/random 's
> pool a hardware RNG.
> nov. 02 22:16:25 labo rngd[19595]: read error
> nov. 02 22:16:25 labo rngd[19595]: read error
>
>
> And, when I run the command below, the intensity of the orange LED does
> not change:
>
>
> cat /dev/random >/dev/null
>
>
> Any idea ?
>
>
> Thanks
> ------------------------------
> ⮪ Reply
> <onerng-talk at lists.onerng.info?subject=Re%3A%20OneRNG%20does%20not%20work%20on%20Ubunti%2021.10>
>   🖂 New topic <onerng-talk at lists.onerng.info>   View topic…
> <http://lists.onerng.info/r/topic/4FHCQZ3tNY9pOsjtwxXi7Q>
> Unsubscribe
> <onerng-talk at lists.onerng.info?subject=Unsubscribe&body=Hello%2C%0A%0APlease%20remove%20me%20from%20OneRNG%20Talk%0A%3Chttp%3A//lists.onerng.info/groups/onerng-talk%3E%0A%0AThank%20you.>
>  •  Switch to a daily digest
> <onerng-talk at lists.onerng.info?subject=Digest%20on&body=Hello%2C%0A%0APlease%20switch%20me%20from%20receiving%20one%20email%20per%20post%20to%20the%20daily%0Adigest%2C%20which%20summarises%20the%20all%20the%20posts%20made%20each%20day%20in%0AOneRNG%20Talk%0A%3Chttp%3A//lists.onerng.info/groups/onerng-talk%3E%0A%0AThank%20you.>
>
>    - Privacy <http://lists.onerng.info/policies/privacy/>
>    - Acceptable Use <http://lists.onerng.info/policies/aup/>
>    - Terms of Service <http://lists.onerng.info/policies/tos/>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ourshack.com/pipermail/discuss/attachments/20211104/2aacb154/attachment.html>


More information about the Discuss mailing list