Giter Site home page Giter Site logo

blueducky's People

Contributors

carrotrub avatar coldvisionz avatar ctkqiang avatar faganafandiyev avatar lamentomori avatar pentestfunctions avatar spicydll avatar xgrimnir avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

blueducky's Issues

ERROR - [TX-19] Bluetooth error: [Errno 104] Connection reset by peer

Trying on Pinephone PRO with Kali Linux, with internal and TP-Link UB500 Bluetooth and i have this error with Huawei Y5 2018 in target Android 8.1.0

2024-05-11 21:08:51,616 - INFO - Reconnection required. Attempting to reconnect...
2024-05-11 21:08:55,876 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 1
2024-05-11 21:08:56,781 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 17
2024-05-11 21:08:57,331 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 19
2024-05-11 21:08:57,367 - ERROR - ERROR connecting on port 19: [Errno 104] Connection reset by peer
2024-05-11 21:08:57,367 - ERROR - Connection failure: Connection failure on port 19
Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (104, 'Connection reset by peer')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 265, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 104] Connection reset by peer

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 697, in
main()
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 679, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 626, in setup_and_connect
establish_connections(connection_manager)
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 618, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 158, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 158, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/home/kali/Pentest/BlueDucky/BlueDucky.py", line 273, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 19

No module named 'utils.menu_functions'; 'utils' is not a package

I am having this error when trying to run blueducky.py :

Traceback (most recent call last):
  File "/root/tools/BlueDucky/BlueDucky.py", line 7, in <module>
    from utils.menu_functions import (main_menu, read_duckyscript, run, restart_bluetooth_daemon, get_target_address)
ModuleNotFoundError: No module named 'utils.menu_functions'; 'utils' is not a package

installation and requirements all met according to the README.md

OS : Kali 2024.1
Chipset : Realtek 0bda:8761 Driver btusb

Bluetooth error: Bad address

OS: Fedora Linux 39 (Workstation Edition)
Kernel: 6.7.9-200.fc39.x86_64
Python Version: 3.12.2

I am getting some bluetooth error while trying to run the program:

                BlueDucky - Bluetooth Device Attacker                 
======================================================================
Remember, you can still attack devices without visibility...
If you have their MAC address
======================================================================

Known devices:
1: Device Name: My_Phone, Address: XX:XX:XX:XX:XX:XX

Do you want to use one of these known devices? (yes/no): yes
Enter the number of the device: 1
2024-03-29 18:58:55,259 - INFO - executing 'sudo service bluetooth restart'
2024-03-29 18:58:56,225 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
2024-03-29 18:58:56,284 - INFO - executing 'hciconfig hci0 name'
2024-03-29 18:58:56,307 - INFO - executing 'sudo hciconfig hci0 class 9536'
2024-03-29 18:58:56,362 - INFO - executing 'hciconfig hci0 class'
2024-03-29 18:58:56,372 - INFO - executing 'sudo hciconfig hci0 sspmode 1'
2024-03-29 18:58:58,682 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 1
2024-03-29 18:59:00,463 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 17
2024-03-29 18:59:02,269 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 19
2024-03-29 18:59:02,320 - ERROR - [TX-19] Bluetooth error: [Errno 14] Bad address
2024-03-29 18:59:04,320 - INFO - Reconnection required. Attempting to reconnect...
2024-03-29 18:59:08,576 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 1
2024-03-29 18:59:10,688 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 17
2024-03-29 18:59:12,378 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 19
2024-03-29 18:59:13,320 - ERROR - [TX-19] Bluetooth error: [Errno 14] Bad address

After that, it continually attempts to reconnect, resulting in errors.

2024-03-29 18:59:04,320 - INFO - Reconnection required. Attempting to reconnect...
2024-03-29 18:59:08,576 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 1
2024-03-29 18:59:10,688 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 17
2024-03-29 18:59:12,378 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 19
2024-03-29 18:59:13,320 - ERROR - [TX-19] Bluetooth error: [Errno 14] Bad address

module error

Hi, new user just joined... Hi people.

I've followed the instruction line for line as root on kali but I keep getting an error telling me that 'utils' is not a package.

┌──(root㉿kali)-[~/BlueDucky]
└─# python3 BlueDucky.py
Traceback (most recent call last):
File "/root/BlueDucky/BlueDucky.py", line 7, in
from utils.menu_functions import (main_menu, read_duckyscript, run, restart_bluetooth_daemon, get_target_address)
ModuleNotFoundError: No module named 'utils.menu_functions'; 'utils' is not a package

┌──(root㉿kali)-[~/BlueDucky]
└─# ls
BlueDucky.py README.md init.py images payloads utils

┌──(root㉿kali)-[~/BlueDucky]
└─# cd utils

┌──(root㉿kali)-[~/BlueDucky/utils]
└─# ls
pycache magic_keyboard_hid.py menu_functions.py register_device.py

please help, i'm new at linux only 3 months.

thanks

error after running script

Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (112, 'Host is down')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/vilen/BlueDucky/BlueDucky.py", line 264, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 112] Host is down

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/vilen/BlueDucky/BlueDucky.py", line 756, in
main()
File "/home/vilen/BlueDucky/BlueDucky.py", line 729, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/vilen/BlueDucky/BlueDucky.py", line 637, in setup_and_connect
establish_connections(connection_manager)
File "/home/vilen/BlueDucky/BlueDucky.py", line 629, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/vilen/BlueDucky/BlueDucky.py", line 157, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/vilen/BlueDucky/BlueDucky.py", line 157, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/home/vilen/BlueDucky/BlueDucky.py", line 278, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 1

Failed to enable SSP

2024-04-01 22:10:27,385 - ERROR - Failed to enable SSP: Can't set Simple Pairing mode on hci0: Input/output error (5)

2024-04-01 22:10:27,386 - ERROR - Error enabling SSP: Failed to enable SSP
Traceback (most recent call last):
File "/root/Desktop/BlueDucky/BlueDucky.py", line 673, in
main()
File "/root/Desktop/BlueDucky/BlueDucky.py", line 647, in main
adapter.enable_ssp()
File "/root/Desktop/BlueDucky/BlueDucky.py", line 111, in enable_ssp
raise ConnectionFailureException("Failed to enable SSP")
ConnectionFailureException: Failed to enable SSP

``
For the first time it run perfectly. When I try to run again it show error .
I am using Kali Linux

how to solve ERROR - ERROR connecting on port 17: [Errno 111]

i am on a laptop using kali i have install all the requirements i tried to use this on samsung A2 core on the first attempt it opened google and then the script suddenly stopped and now i am getting this error

Available payloads:
[1]: payload_example_2.txt
[2]: payload_example_1.txt
[3]: wp_payload.txt

Enter the number that represents the payload you would like to load: 1
Selected payload: /home/sujal/BlueDucky/payloads/payload_example_2.txt
2024-05-23 19:43:29,390 - INFO - executing 'sudo service bluetooth restart'
[sudo] password for sujal:
2024-05-23 19:43:34,041 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
2024-05-23 19:43:34,096 - INFO - executing 'hciconfig hci0 name'
2024-05-23 19:43:34,114 - INFO - executing 'sudo hciconfig hci0 class 9536'
2024-05-23 19:43:34,134 - INFO - executing 'hciconfig hci0 class'
2024-05-23 19:43:34,140 - INFO - executing 'sudo hciconfig hci0 sspmode 1'
2024-05-23 19:43:36,412 - INFO - connecting to 38:EA:C1:3B:AE:AB on port 1
2024-05-23 19:43:36,854 - INFO - connecting to 38:EA:C1:3B:AE:AB on port 17
2024-05-23 19:43:37,010 - ERROR - ERROR connecting on port 17: [Errno 111] Connection refused
2024-05-23 19:43:37,010 - ERROR - Connection failure: Connection failure on port 17
-e remove 38:EA:C1:3B:AE:ABoothd...[bluetooth]# Leaf Bass 2
Invalid command in menu main: -e

Use "help" for a list of available commands in a menu.
Use "menu " if you want to enter any submenu.
Use "back" if you want to return to menu main.
[Leaf Bass 2]# Successfully Removed device: 38:EA:C1:3B:AE:AB
Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (111, 'Connection refused')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/sujal/BlueDucky/./BlueDucky.py", line 264, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/sujal/BlueDucky/./BlueDucky.py", line 755, in
main()
File "/home/sujal/BlueDucky/./BlueDucky.py", line 728, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/sujal/BlueDucky/./BlueDucky.py", line 637, in setup_and_connect
establish_connections(connection_manager)
File "/home/sujal/BlueDucky/./BlueDucky.py", line 629, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/sujal/BlueDucky/./BlueDucky.py", line 157, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/sujal/BlueDucky/./BlueDucky.py", line 157, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/home/sujal/BlueDucky/./BlueDucky.py", line 278, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 17

Ducky Commands

How does the keycode hex values work, im trying to find the power off keycode and still never found it.

Can I atleast know how you got these values and any extra information for me to help?

Error: Can't change local name on hci0: Network is down (100)

Available payloads:
[1]: payload_example_2.txt
[2]: payload_example_1.txt
[3]: wp_payload.txt

Enter the number that represents the payload you would like to load: 2
Selected payload: /home/kali/BlueDucky-main/payloads/payload_example_1.txt
2024-05-27 15:45:50,483 - INFO - executing 'sudo service bluetooth restart'
2024-05-27 15:45:51,443 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
Traceback (most recent call last):
File "/home/kali/BlueDucky-main/BlueDucky.py", line 755, in
main()
File "/home/kali/BlueDucky-main/BlueDucky.py", line 719, in main
adapter = setup_bluetooth(target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky-main/BlueDucky.py", line 615, in setup_bluetooth
adapter.set_property("name", "Robot POC")
File "/home/kali/BlueDucky-main/BlueDucky.py", line 87, in set_property
self._run_command(command)
File "/home/kali/BlueDucky-main/BlueDucky.py", line 81, in _run_command
raise ConnectionFailureException(f"Failed to execute command: {' '.join(command)}. Error: {result.stderr}")
ConnectionFailureException: Failed to execute command: sudo hciconfig hci0 name Robot POC. Error: Can't change local name on hci0: Network is down (100)

Connection Reset by peer

Screenshot from 2024-03-17 17-12-35
I have tried to use a Ducky script BUT whenever the script takes more than 3 seconds to finish, it just restarts the whole process.
Does anyone know why and how to fix it.

Tab key is not injecting

I have tried many times to inject TAB. it showing that it's done but it is not injecting TAB give me solution please

ERROR connecting on port 17: [Errno 103] Software caused connection abort

Enter the number of the payload you want to load: 1
Selected payload: /home/smartboy/BlueDucky/payloads/payload_example_1.txt
2024-04-23 04:05:34,694 - INFO - executing 'sudo service bluetooth restart'
2024-04-23 04:05:35,873 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
2024-04-23 04:05:35,943 - INFO - executing 'hciconfig hci0 name'
2024-04-23 04:05:35,952 - INFO - executing 'sudo hciconfig hci0 class 9536'
2024-04-23 04:05:36,005 - INFO - executing 'hciconfig hci0 class'
2024-04-23 04:05:36,019 - INFO - executing 'sudo hciconfig hci0 sspmode 1'
2024-04-23 04:05:40,290 - INFO - connecting to 0C:9A:3C:41:96:5E on port 1
2024-04-23 04:05:41,045 - INFO - connecting to 0C:9A:3C:41:96:5E on port 17
2024-04-23 04:05:41,917 - ERROR - ERROR connecting on port 17: [Errno 103] Software caused connection abort
2024-04-23 04:05:41,918 - ERROR - Connection failure: Connection failure on port 17
Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (103, 'Software caused connection abort')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/smartboy/BlueDucky/BlueDucky.py", line 265, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 103] Software caused connection abort

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/smartboy/BlueDucky/BlueDucky.py", line 697, in
main()
File "/home/smartboy/BlueDucky/BlueDucky.py", line 679, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartboy/BlueDucky/BlueDucky.py", line 626, in setup_and_connect
establish_connections(connection_manager)
File "/home/smartboy/BlueDucky/BlueDucky.py", line 618, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartboy/BlueDucky/BlueDucky.py", line 158, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/smartboy/BlueDucky/BlueDucky.py", line 158, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/home/smartboy/BlueDucky/BlueDucky.py", line 273, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 17

attacking same device only working sometimes

2024-03-25 09:15:17,044 - ERROR - ERROR connecting on port 17: [Errno 111] Connection refused
2024-03-25 09:15:17,045 - ERROR - Connection failure: Connection failure on port 17
Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (111, 'Connection refused')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/BlueDucky/BlueDucky.py", line 264, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 111] Connection refused

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/BlueDucky/BlueDucky.py", line 668, in
main()
File "/BlueDucky/BlueDucky.py", line 650, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/BlueDucky/BlueDucky.py", line 625, in setup_and_connect
establish_connections(connection_manager)
File "/BlueDucky/BlueDucky.py", line 617, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/BlueDucky/BlueDucky.py", line 157, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/BlueDucky/BlueDucky.py", line 157, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/BlueDucky/BlueDucky.py", line 272, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 17

Edit attacking device are a phone with nethunter attacking another android phone with android 10

Failed to execute command: sudo hciconfig hci0 name Robot POC.

im using Raspberry pi 4 and Kali linux 2024.1

Known devices:
1: Device Name: Galaxy J4+, Address: 88:9F:6F:6E:D4:BB

Do you want to use one of these known devices? (yes/no): yes
Enter the number of the device: 1
2024-03-27 16:35:28,399 - INFO - executing 'sudo service bluetooth restart'
2024-03-27 16:35:29,352 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky.py", line 668, in
main()
File "/home/kali/BlueDucky/BlueDucky.py", line 641, in main
adapter = setup_bluetooth(target_address)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 603, in setup_bluetooth
adapter.set_property("name", "Robot POC")
File "/home/kali/BlueDucky/BlueDucky.py", line 87, in set_property
self._run_command(command)
File "/home/kali/BlueDucky/BlueDucky.py", line 81, in _run_command
raise ConnectionFailureException(f"Failed to execute command: {' '.join(command)}. Error: {result.stderr}")
ConnectionFailureException: Failed to execute command: sudo hciconfig hci0 name Robot POC. Error: Can't change local name on hci0: Network is down (100)
__

ModuleNotFoundError: No module named '_dbus_bindings'

Can't able to start Blueducky.py

❯ git clone https://github.com/pentestfunctions/BlueDucky.git
cd BlueDucky
sudo hciconfig hci0 up
python3 BlueDucky.py
Cloning into 'BlueDucky'...
remote: Enumerating objects: 162, done.
remote: Counting objects: 100% (60/60), done.
remote: Compressing objects: 100% (37/37), done.
remote: Total 162 (delta 35), reused 43 (delta 22), pack-reused 102
Receiving objects: 100% (162/162), 803.75 KiB | 3.32 MiB/s, done.
Resolving deltas: 100% (69/69), done.
Traceback (most recent call last):
  File "/home/USER/BlueDucky/BlueDucky.py", line 8, in <module>
    from utils.register_device import register_hid_profile, agent_loop
  File "/home/USER/BlueDucky/utils/register_device.py", line 1, in <module>
    import dbus
  File "/usr/lib/python3/dist-packages/dbus/__init__.py", line 73, in <module>
    import dbus.types as types
  File "/usr/lib/python3/dist-packages/dbus/types.py", line 8, in <module>
    from _dbus_bindings import (
ModuleNotFoundError: No module named '_dbus_bindings'

Connection reset

I encountered a problem, when I run the script it reboots after 3 seconds. What could this be related to?
UPD:
Снимок экрана 2024-02-24 192356

tool not working on kali linux

i followed all the steps but doesnt work

Traceback (most recent call last):
File "/home/samir/BlueDucky/BlueDucky.py", line 1, in
import binascii, bluetooth, sys, time, datetime, logging
ModuleNotFoundError: No module named 'bluetooth'

Error with Bluetooth adaptor csr 4.0

Hey when I use the adaptor above I get the following error : Can’t initiate hci0 . Broken pipe (32). Does anyone know that that is and how to fix.?

New payloads

Does anyone have any more interesting payload ideas or example? Maybe download and open a file from a specific website ?

Not running on my Kali(2024.1), different kind of error compared to the other ones

Hey, there I've literally installed everything step by step from the readme.md file but everytime when I try to run the script even with sudo enabled I get the following error(my bluetooth card(hci0) is perfectly functional and I have no idea why im getting the following error)), I'd be more than thankful if someone could help me out <3

2024-04-04 15:27:57,634 - INFO - executing 'sudo service bluetooth restart'
2024-04-04 15:27:58,496 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
Traceback (most recent call last):
File "/home/andrew/Downloads/BlueDucky/BlueDucky.py", line 673, in
main()
File "/home/andrew/Downloads/BlueDucky/BlueDucky.py", line 646, in main
adapter = setup_bluetooth(target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/andrew/Downloads/BlueDucky/BlueDucky.py", line 603, in setup_bluetooth
adapter.set_property("name", "Robot")
File "/home/andrew/Downloads/BlueDucky/BlueDucky.py", line 87, in set_property
self._run_command(command)
File "/home/andrew/Downloads/BlueDucky/BlueDucky.py", line 81, in _run_command
raise ConnectionFailureException(f"Failed to execute command: {' '.join(command)}. Error: {result.stderr}")
ConnectionFailureException: Failed to execute command: sudo hciconfig hci0 name Robot. Error: Can't change local name on hci0: Network is down (100)

E: Unable to locate package install ERROR

E: Unable to locate package install error
while running
sudo apt install -y python3-pydbus command

log

sudo apt install -y git gcc python3-pip python3-setuptools
sudo apt install -y python3-pydbus
[sudo] password for kali:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package install
E: Unable to locate package install

Failed to execute command: sudo hciconfig hci0 name Robot POC.

Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky.py", line 697, in
main()
File "/home/kali/BlueDucky/BlueDucky.py", line 670, in main
adapter = setup_bluetooth(target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 604, in setup_bluetooth
adapter.set_property("name", "Robot POC")
File "/home/kali/BlueDucky/BlueDucky.py", line 88, in set_property
self._run_command(command)
File "/home/kali/BlueDucky/BlueDucky.py", line 82, in _run_command
raise ConnectionFailureException(f"Failed to execute command: {' '.join(command)}. Error: {result.stderr}")
ConnectionFailureException: Failed to execute command: sudo hciconfig hci0 name Robot POC. Error: Can't change local name on hci0: Network is down (100)

How to fix this?

python3 BlueDucky.py
Traceback (most recent call last):
File "/root/BlueDucky/BlueDucky.py", line 7, in
from utils.menu_functions import (main_menu, read_duckyscript, run, restart_bluetooth_daemon, get_target_address)
ModuleNotFoundError: No module named 'utils.menu_functions'; 'utils' is not a package

utils error

Traceback (most recent call last):
File "/home/nigm/BlueDucky/BlueDucky.py", line 7, in
from utils.menu_functions import (main_menu, read_duckyscript, run, restart_bluetooth_daemon, get_target_address)
ModuleNotFoundError: No module named 'utils.menu_functions'; 'utils' is not a package

OSError: [Errno 19] No such device. how to fix it

Attempting to scan now...
Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky/BlueDucky.py", line 697, in
main()
File "/home/kali/BlueDucky/BlueDucky/BlueDucky.py", line 637, in main
target_address = get_target_address()
^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky/utils/menu_functions.py", line 7, in get_target_address
devices = scan_for_devices()
^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky/utils/menu_functions.py", line 126, in scan_for_devices
nearby_devices = bluetooth.discover_devices(duration=8, lookup_names=True, flush_cache=True, lookup_class=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/PyBluez-0.30-py3.11-linux-x86_64.egg/bluetooth/bluez.py", line 19, in discover_devices
OSError: [Errno 19] No such device

please help me

No module named 'bluetooth'

Traceback (most recent call last):
File "/home/kali/Desktop/tools/BlueDucky/./BlueDucky.py", line 1, in
import binascii, bluetooth, sys, time, datetime, logging, argparse
ModuleNotFoundError: No module named 'bluetooth'

No connection

Im able to detected bluetooth devices on raspbian

but still getting everytime

ERROR - ERROR connecting on port 1: [Errno 103] Software caused connection abort
ERROR - Connection failure: Connection failure on port 1
Traceback (most recent call last):
  File "<string>", line 3, in connect
_bluetooth.error: (103, 'Software caused connection abort')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/root/BlueDucky/BlueDucky.py", line 264, in connect
    sock.connect((self.addr, self.port))
  File "<string>", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 103] Software caused connection abort

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/root/BlueDucky/BlueDucky.py", line 668, in <module>
    main()
  File "/root/BlueDucky/BlueDucky.py", line 650, in main
    hid_interrupt_client = setup_and_connect(connection_manager, target_address)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/BlueDucky/BlueDucky.py", line 625, in setup_and_connect
    establish_connections(connection_manager)
  File "/root/BlueDucky/BlueDucky.py", line 617, in establish_connections
    if not connection_manager.connect_all():
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/BlueDucky/BlueDucky.py", line 157, in connect_all
    return sum(client.connect() for client in self.clients.values())
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/BlueDucky/BlueDucky.py", line 157, in <genexpr>
    return sum(client.connect() for client in self.clients.values())
               ^^^^^^^^^^^^^^^^
  File "/root/BlueDucky/BlueDucky.py", line 272, in connect
    raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 1

on my mobile phone I briefly get a popup witrh a pairing code but endup with the above error

What may be causing this?

Thank you

Devices asking to be paired

I need to pair the device manually to send the keystrokes, I have a Qualcomm Atheros qca9377 Bluetooth driver.

Connection failure: Connection failure on port 17

im having this weird issue when trying to execute on a device, im using a raspberry pi zero 2w:

Known devices:
1: Device Name: Hyena's S21 Ultra, Address: XX:XX:XX:XX:XX:XX

Do you want to use one of these known devices? (yes/no): yes
Enter the number of the device: 1
2024-04-01 10:59:00,440 - INFO - executing 'sudo service bluetooth restart'
2024-04-01 10:59:01,478 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
2024-04-01 10:59:01,526 - INFO - executing 'hciconfig hci0 name'
2024-04-01 10:59:01,532 - INFO - executing 'sudo hciconfig hci0 class 9536'
2024-04-01 10:59:01,578 - INFO - executing 'hciconfig hci0 class'
2024-04-01 10:59:01,588 - INFO - executing 'sudo hciconfig hci0 sspmode 1'
2024-04-01 10:59:03,994 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 1
2024-04-01 10:59:05,294 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 17
2024-04-01 10:59:05,908 - ERROR - ERROR connecting on port 17: [Errno 103] Software caused connection abort
2024-04-01 10:59:05,908 - ERROR - Connection failure: Connection failure on port 17
Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (103, 'Software caused connection abort')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky.py", line Select a device by number: 1
2024-04-01 11:22:54,927 - INFO - executing 'sudo service bluetooth restart'
2024-04-01 11:22:55,965 - INFO - executing 'sudo hciconfig hci0 name Robot POC'
2024-04-01 11:22:56,011 - INFO - executing 'hciconfig hci0 name'
2024-04-01 11:22:56,017 - INFO - executing 'sudo hciconfig hci0 class 9536'
2024-04-01 11:22:56,062 - INFO - executing 'hciconfig hci0 class'
2024-04-01 11:22:56,071 - INFO - executing 'sudo hciconfig hci0 sspmode 1'
2024-04-01 11:22:58,482 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 1
2024-04-01 11:22:59,606 - INFO - connecting to XX:XX:XX:XX:XX:XX on port 17
2024-04-01 11:23:00,408 - ERROR - ERROR connecting on port 17: [Errno 103] Software caused connection abort
2024-04-01 11:23:00,409 - ERROR - Connection failure: Connection failure on port 17
Traceback (most recent call last):
File "", line 3, in connect
_bluetooth.error: (103, 'Software caused connection abort')

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky.py", line 264, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 103] Software caused connection abort

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky.py", line 673, in
main()
File "/home/kali/BlueDucky/BlueDucky.py", line 655, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 625, in setup_and_connect
establish_connections(connection_manager)
File "/home/kali/BlueDucky/BlueDucky.py", line 617, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 157, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 157, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 272, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 17, in connect
sock.connect((self.addr, self.port))
File "", line 5, in connect
bluetooth.btcommon.BluetoothError: [Errno 103] Software caused connection abort

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/kali/BlueDucky/BlueDucky.py", line 673, in
main()
File "/home/kali/BlueDucky/BlueDucky.py", line 655, in main
hid_interrupt_client = setup_and_connect(connection_manager, target_address, adapter_id)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 625, in setup_and_connect
establish_connections(connection_manager)
File "/home/kali/BlueDucky/BlueDucky.py", line 617, in establish_connections
if not connection_manager.connect_all():
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 157, in connect_all
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 157, in
return sum(client.connect() for client in self.clients.values())
^^^^^^^^^^^^^^^^
File "/home/kali/BlueDucky/BlueDucky.py", line 272, in connect
raise ConnectionFailureException(f"Connection failure on port {self.port}")
ConnectionFailureException: Connection failure on port 17

Using External BT hci1

Hello nice work!!
I can't use with external BT adapter (hci1) only works for hci0?
Saludos

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.