# DHCPain
DHCPain is a simple, no-nonsense DHCP attack toolkit built in Scapy for Python3. It is capable of locating all DHCP servers on the network as well as exhausting DHCP scopes by responding to DHCP Offer messages.
### Purpose Some attack utilities either do not work with the current version of Scapy (such as [DHCPig](https://github.com/kamorin/DHCPig)), or only floods the network with DHCP Discover packets without properly responding to DHCP Offer messages. This tool is simple and fixes both of these issues.
### Setup
git clone https://github.com/GoodiesHQ/DHCPain
Though it is not required, it is recommended to install DHCPain into a virtual environment.
python3 -m virtualenv DHCPain cd DHCPain
# Linux . bin/activate
# Windows Scriptsactivate.bat
Once your environment is ready, simply install the requirements. DHCPain is a standalone python file.
pip install -r requirements.txt python dhcpain.py
### Usage
usage: dhcpain.py [-h] (–iface IFACE | –list) [–threads THREADS] [–delay DELAY]
- optional arguments:
- -h, --help
show this help message and exit
- --iface IFACE, -i IFACE
Interface name/index
- --list, -l
List available interfaces
- --threads THREADS, -t THREADS
Number of concurrent threads
- --delay DELAY, -d DELAY
Delay between messages per thread
### Example (Linux) With Linux, the common interface name is the only thing necessary for execution:  
### Example (Windows) On Windows, you will need to provide either the complete interface name, or the index. In this case, either of these two commands would operate the same way:
python dhcpain.py –iface 28 python dhcpain.py –iface “Intel(R) Dual Band Wireless-AC 8275”

Once the interface is selected, it will perform as normal:

Metadata
Release files for dhcpain 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| dhcpain-1.0.0.tar.gz | 5.0 kB | Without provenance | Details for dhcpain-1.0.0.tar.gz |
Release files / dhcpain-1.0.0.tar.gz
| Download URL | dhcpain-1.0.0.tar.gz |
|---|---|
| Size | 5.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0ac73404df2f1e758ef5291350aa7b848290488b7a12bf5117d3e1a4b88c39ea
|
|
BLAKE2b-256 checksum How to use checksums |
bcb6a0d29c486b2a9a2708e29320d7afd4c3fd4dbd3b806c43bc0e25751fbc6a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/44.0.0 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.7.6
|
Security for dhcpain 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.