mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-23 01:06:52 +00:00
Update device_tracker.bluetooth_le_tracker.markdown (#7174)
hcitool generates permission denied unless you perform a similar setcap option as you need to with python3
This commit is contained in:
parent
efccd44170
commit
e7d0244615
@ -54,11 +54,12 @@ Some BTLE devices (e.g., fitness trackers) are only visible to the devices that
|
||||
|
||||
## {% linkable_title Rootless Setup %}
|
||||
|
||||
Normally accessing the Bluetooth stack is reserved for root, but running programs that are networked as root is a bad security wise. To allow non-root access to the Bluetooth stack we can give Python 3 the missing capabilities to access the Bluetooth stack. Quite like setting the setuid bit (see [Stack Exchange](http://unix.stackexchange.com/questions/96106/bluetooth-le-scan-as-non-root) for more information).
|
||||
Normally accessing the Bluetooth stack is reserved for root, but running programs that are networked as root is a bad security wise. To allow non-root access to the Bluetooth stack we can give Python 3 and hcitool the missing capabilities to access the Bluetooth stack. Quite like setting the setuid bit (see [Stack Exchange](http://unix.stackexchange.com/questions/96106/bluetooth-le-scan-as-non-root) for more information).
|
||||
|
||||
```bash
|
||||
$ sudo apt-get install libcap2-bin
|
||||
$ sudo setcap 'cap_net_raw,cap_net_admin+eip' `readlink -f \`which python3\``
|
||||
$ sudo setcap 'cap_net_raw+ep' `readlink -f \`which hcitool\``
|
||||
```
|
||||
|
||||
A restart of Home Assistant is required.
|
||||
|
Loading…
x
Reference in New Issue
Block a user