From Fedora Project Wiki

Revision as of 10:57, 21 July 2016 by Mildew (talk | contribs) (Created page with "{{QA/Test_Case |description=This test case tests {{package|usbguard}} initial setup procedure. |setup= # Ensure the {{package|usbguard}} package is installed # To start from a...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Description

This test case tests Package-x-generic-16.pngusbguard initial setup procedure.

Setup

  1. Ensure the Package-x-generic-16.pngusbguard package is installed
  2. To start from a clean state, ensure that the usbguard service is stopped and that there's no existing policy.
  3. Ensure that there's at least one USB device connected to your system which can be disconnected and connected again. For example a USB keyboard or mouse.
  4. Prepare a USB device which is not connected to the system. For example a USB flash drive.
Idea.png
How to get to a clean state
As root, run systemctl stop usbguard and rm -f /etc/usbguard/rules.conf

How to test

  1. As root, generate an initial policy using the following command: usbguard generate-policy -P > /etc/usbguard/rules.conf
  2. Start the usbguard service: systemctl start usbguard
  3. Check that your connected USB devices are still working. Try to reconnect some of them and check that they are still working.
  4. Connect the new device to the system and try whether it's working.
Note.png
The -P option in usbguard generate-policy
The option causes the command not to generate port-specific rules. You can leave it out if you'll use the same port when reconnecting a device in a later step.

Expected Results

  1. USB devices work after the usbguard service start.
  2. Reconnected USB devices work.
  3. Newly connected USB devices do not work.