]> gitweb.fluxo.info Git - puppet-nodo.git/commitdiff
Basic BadUSB mitigation
authorSilvio Rhatto <rhatto@riseup.net>
Tue, 30 Jun 2015 16:31:24 +0000 (13:31 -0300)
committerSilvio Rhatto <rhatto@riseup.net>
Tue, 30 Jun 2015 16:31:24 +0000 (13:31 -0300)
files/etc/rc.local

index 4ce3a3ae3f286b389e952bbe8758a206091e47e3..b2ca780245fca7b73190808d9692f9dd08bb2c30 100644 (file)
@@ -40,5 +40,10 @@ if [ -f "/etc/screenrc.startup" ]; then
   ( . /etc/default/locale && cd /root && HOME=/root LANG=$LANG /usr/bin/screen -d -m -S root -c /etc/screenrc.startup )
 fi
 
+# See https://links.sarava.org/tags/badusb
+if [ -e "/sys/module/usbcore/parameters/authorized_default" ]; then
+  echo "0" > /sys/module/usbcore/parameters/authorized_default
+fi
+
 # Then exit
 exit 0