Can Firejail disable USB access? If so, how?
Jump to turn (6)
- 1Can Firejail disable USB access? If so, how?
- 2If one doesn't specify anything related to seccomp, is it enabled for everything
- 3If the operating system drive is being run from USB, is it enough to restrict ac
- 4I meant in the firejail situation I had described before, not in general.
- 5I meant just for within the Firejail sandbox. What if I did want to restrict USB
- 6For 1, I meant if I restrict access to the directions of the USB drive that the
- User
Can Firejail disable USB access? If so, how?
- Assistant
Yes, Firejail can disable USB access. It achieves this by using a seccomp-bpf filter, which allows a user to restrict system calls made by an application. The use of seccomp filters ensures a more secure environment while running the application within a Firejail sandbox.
To disable USB access with Firejail, you need to create a seccomp filter profile. Here's an example of a profile that blocks USB device access:
- Create a file named "usb-filter.profile" (or any other name you prefer) with the following content:
codeblacklist deny /dev/bus/usb/* blacklist deny /dev/usb/* deny /proc/sys/kernel/hotplug- Launch Firejail using the created profile by executing the command: