Enabling Bluetooth on Qubes R4.1

After some more months of experience with this OS I believe I can indeed answer your question. I have not tried this myself as I don’t need to use a bluetooth keyboard in my use-case, but I believe that QubesOS has not specifically blocked the ability to use one. In order to set this up, I believe it should be the same process as with your Bluetooth Mouse, but with one final difference: You will notice above that in order to make the mouse work in dom0, you needed to modify the file at

/etc/qubes-rpc/policy/qubes.InputMouse

If you navigate to that directory in a dom0 terminal cd /etc/qubes-rpc/policy/ and list the contents using ls, you will see that there is also a file there called qubes.InputKeyboard. I believe that file needs to be modified just like the mouse file needed to be to tell QubesOS to accept the keyboard under certain conditions. In total, I would suggest the following process:

  1. Temporarily connect bluetooth hardware (usually wifi card) and possibly USB controller to the Template VM of your sys-usb VM (need to change the Template to HVM probably to do this)

  2. Run Template VM and pair the device (keyboard or mouse)

  3. Open the Qubes RPC policy file and tell it to ask when it detects the Input Device being connected. I like to do this in nano, since I am not a Linux Veteran yet. sudo nano /etc/qubes-rpc/policy/qubes.InputKeyboard . Although you certainly do as suggested just above using echo, if you prefer.

  4. Add the following line to the top of the file sys-usb dom0 ask,user=root,default_target=dom0, and I personally keep the second line as it already is just in case it is helpful to deny any other cases that I don’t approve $anyvm $anyvm deny.

  5. Save the file and exit nano. Also, Make certain to remove the Bluetooth and USB controllers from the TemplateVM once you have paired the keyboard or mouse, and convert it make to PVH mode if changed.

Let me know if this works for you. I haven’t tried and I probably won’t, but if your use-case requires the keyboard, then I hope this helps!

1 Like