- 之前在蓝色的开关按钮处无法打开蓝牙,在执行界面执行以下命令即可正常打开蓝牙了:
┌──(***㉿kali)-[~/桌面]
└─$ sudo service bluetooth start
- GUI连接
- 手动连接(蓝牙的地址是固定的,如果事先知道可以去掉scan)
[bluetooth]# scan on
[NEW] Device 蓝牙的地址 蓝牙的名称
在实际操作中scan on 的输出会一直更新,这里进行了删除
[bluetooth]# scan off
列出刚才扫描的总结
[bluetooth]# devices
展示一下信息
[bluetooth]# info 蓝牙的地址
[bluetooth]# connect 蓝牙的地址
Attempting to connect to **:**:**:**:**:**
[CHG] Device D8:9B:3B:6E:27:1C Connected: yes
[CHG] Device D8:9B:3B:6E:27:1C Modalias: bluetooth:v010Fp107Ed1436
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00000000-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 0000046a-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001105-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 0000110a-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 0000110c-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001112-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001115-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001116-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 0000111f-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 0000112f-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001132-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001200-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001800-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 00001801-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C UUIDs: 0000fe35-0000-1000-8000-00805f9b34fb
[CHG] Device D8:9B:3B:6E:27:1C ServicesResolved: yes
[CHG] Device 5A:0D:E6:99:FC:9B RSSI: -74
Request confirmation
[agent] Confirm passkey 116765 (yes/no):
-
输入yes
-
然后在手机或其他设备将收到链接请求,点击确认
[agent] Authorize service 00001108-0000-1000-8000-00805f9b34fb (yes/no):
最后power off
关闭蓝牙
参考与更多
- 设置自己能否被其他人发现
[bluetooth]# discoverable on
Changing discoverable on succeeded
给自己的蓝牙改名为haha
[bluetooth]# system-alias haha
Changing haha succeeded
[bluetooth]# discoverable off
Changing discoverable off succeeded
Bluez
Enter the bluetoothctl shell:
bluetoothctl
List devices:
bluetoothctl -- devices
Pair a device:
bluetoothctl -- pair {{mac_address}}
Remove a device:
bluetoothctl -- remove {{mac_address}}
Connect a paired device:
bluetoothctl -- connect {{mac_address}}
Disconnect a paired device:
bluetoothctl -- disconnect {{mac_address}}