Code Monkey home page Code Monkey logo

bluetooth_smp_pocs's Introduction

Bluetooth SMP PoCs

This repository contains proof-of-concepts for attacks against the BLE SMP protocols when a static passkey is used. More information can be found in the corresponding Insinuator blogpost.

SMP Bruteforce

The bruteforce script requires Internalblue and pycryptodome to be installed. You will either need CAP_NET_RAW or root privileges to use the required HCI socket. Additionally, the Bluetooth device needs to be down. You can simply run systemctl stop bluetooth to do that.

To run the script you need to Bluetooth address of the device you want to brute-force. Run the script as follows:

python smp_bruteforce.py AA:BB:CC:DD:EE:FF

Successfully running the script looks as follows:

smp_bruteforce script excecution GIF

bluetooth_smp_pocs's People

Contributors

ttdennis 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

Watchers

 avatar

bluetooth_smp_pocs's Issues

dont work

─$ sudo python smp_bruteforce.py 56:a4:78:7a:0b:50

dpkg-query: no path found matching pattern bin/armeabilinux*-as*
Could not find 'as' installed for ContextType(arch = 'thumb', bits = 32, endian = 'little')
Try installing binutils for this architecture:
https://docs.pwntools.com/en/stable/install/binutils.html
[!] pwnlib.asm.which_binutils() cannot find 'as'!
[!] pwntools cannot find binutils for arm architecture. Disassembling will not work!
[!] Found 1 HCI devices via ioctl(HCIGETDEVLIST)!
[] HCI device: hci0 [77:22:34:44:55:77] flags=5
[!] Found 1 HCI devices via ioctl(HCIGETDEVLIST)!
[
] HCI device: hci0 [77:22:34:44:55:77] flags=5
[ERROR] Unable to bind
[*] Connected to hci0
[!] Receive Thread started.
[!] Send Thread started.
[!] _sendThreadFunc: No response from the firmware.
[!] sendHciCommand: waiting for response timed out!
[!] initialize_fimware: Failed to send a HCI command to the Bluetooth driver.
adb: Check if you installed a custom bluetooth.default.so properly on your
Android device. bluetooth.default.so must contain the string 'hci_inject'.
hci: You might have insufficient permissions to send this type of command.
[!] connect: Failed to initialize firmware!
CRITICAL:root:No connection to internalblue device.
same issue , ı closed first issue sory.

NameError: name 'log' is not defined

─$ python smp_bruteforce.py 64:48:fc:37:35:82
[!] Found 1 HCI devices via ioctl(HCIGETDEVLIST)!
[] HCI device: hci0 [11:22:33:44:55:66] flags=5
[!] Found 1 HCI devices via ioctl(HCIGETDEVLIST)!
[
] HCI device: hci0 [11:22:33:44:55:66] flags=5
[ERROR] Unable to bind
[*] Connected to hci0
[!] Receive Thread started.
[!] Send Thread started.
[!] _sendThreadFunc: No response from the firmware.
[!] sendHciCommand: waiting for response timed out!
[!] initialize_fimware: Failed to send a HCI command to the Bluetooth driver.
adb: Check if you installed a custom bluetooth.default.so properly on your
Android device. bluetooth.default.so must contain the string 'hci_inject'.
hci: You might have insufficient permissions to send this type of command.
[!] connect: Failed to initialize firmware!
Traceback (most recent call last):
File "/home/kali/Downloads/bluetooth_smp_pocs/smp_bruteforce/smp_bruteforce.py", line 216, in
main()
File "/home/kali/Downloads/bluetooth_smp_pocs/smp_bruteforce/smp_bruteforce.py", line 205, in main
log.critical("No connection to internalblue device.")
NameError: name 'log' is not defined
how can ı fix

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.