waywardgeek / infnoise

The world's easiest TRNG to get right
Creative Commons Zero v1.0 Universal
723 stars 99 forks source link

infinite loop of syslog "did not claim interface 0 before use" messages #91

Closed gilbert-fernandes closed 3 years ago

gilbert-fernandes commented 3 years ago

Ubuntu 20.04 LTS Installed infnoise from the apt in version 0.3.1+dfsg-1 amd64

ID: 0, Manufacturer: 13-37.org, Description: Infinite Noise TRNG, Serial: 1337-XXXXXXXX

When launching infnoise in daemon mode : gf@orion:~$ sudo infnoise --dev-random --daemon

The lapotp fans start running fast and the /var/log/syslog fills with hundred of the following lines per second in infinite loop until the process is killed :

Feb 18 21:16:03 orion kernel: [45949.551186] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551197] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551206] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551213] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551223] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551230] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551240] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551248] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551266] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use
Feb 18 21:16:03 orion kernel: [45949.551275] usb 3-4: usbfs: process 83592 (infnoise) did not claim interface 0 before use

After a minute this added 59650431 lines to my syslog Adding about 6 Gb of logs...

Seems I am running the latest available version, installed through apt. TRNG key brand new.

gilbert-fernandes commented 3 years ago

Ok I think I should not be trying to start the infnoise in daemon mode manually.

Once the infnoise package is installed, a service is available And it already starts the device in daemon mode and injects data into the system random pool :

gf@orion:~/Documents/infnoise/software$ systemctl status infnoise
● infnoise.service - Wayward Geek InfNoise TRNG driver
     Loaded: loaded (/lib/systemd/system/infnoise.service; enabled; vendor preset: enabled)
     Active: active (running) since Thu 2021-02-18 21:38:40 CET; 2s ago
       Docs: man:infnoise.service(8)
    Process: 84837 ExecStart=/usr/sbin/infnoise --dev-random --daemon --pidfile /var/run/infnoise.pid>
   Main PID: 84838 (infnoise)
      Tasks: 1 (limit: 18644)
     Memory: 652.0K
     CGroup: /system.slice/infnoise.service
             └─84838 /usr/sbin/infnoise --dev-random --daemon --pidfile /var/run/infnoise.pid

So Ubuntu 20.04 + apt package we have to use systemctl And it all works fine...