How To Install Pyrit In Kali Linux May 2026

Pyrit shines at precomputing Pairwise Master Keys:

pyrit -i wordlist.txt create_db
pyrit -i wordlist.txt import_passwords
pyrit batch

Once installed, you can benchmark your system to see how many keys per second (k/s) it can handle:

pyrit benchmark

To attack a capture file (assuming you have a .cap file and a wordlist):

pyrit -r handshake.cap -i wordlist.txt attack_passthrough

Summary: While Pyrit is a powerful tool for WPA auditing, it is considered legacy software. If you encounter significant dependency issues, consider using modern alternatives like Hashcat (hashcat -m 22000), which is actively maintained and pre-installed on Kali Linux.

To install Pyrit on Kali Linux, you must build it from source because it was removed from the official repositories due to its reliance on Python 2. Modern versions of Kali Linux (2021 and newer) require specific dependencies and code modifications to ensure compatibility. Prerequisites

Before starting, ensure your system is up to date. Open a terminal and run: sudo apt update && sudo apt upgrade -y Use code with caution. Copied to clipboard 1. Install Dependencies

Pyrit requires several development libraries to compile correctly. Install them using the following command: sudo apt install git python2-dev libssl-dev libpcap-dev -y Use code with caution. Copied to clipboard

Note: If python2-dev is not found, you may need to add legacy Debian sources (like Debian Stretch) temporarily to your /etc/apt/sources.list. 2. Clone the Pyrit Repository

Download the latest source code from the official GitHub repository maintained by the community: How to install Pyrit in Kali Linux

git clone https://github.com/JPaulMora/Pyrit.git --depth=1 cd Pyrit Use code with caution. Copied to clipboard 3. Modify Source Code for Modern Kali

To prevent compilation errors on modern Kali Rolling releases, you must apply a specific "fudge" to the AESNI code:

sed -i "s/COMPILE_AESNI/COMPILE_AESNIX/" cpyrit/_cpyrit_cpu.c Use code with caution. Copied to clipboard 4. Compile and Install

Run the following commands to build and install the application: Clean previous builds: python2 setup.py clean Use code with caution. Copied to clipboard Build Pyrit: python2 setup.py build Use code with caution. Copied to clipboard Install to System: sudo python2 setup.py install Use code with caution. Copied to clipboard 5. Verify the Installation Check if Pyrit is working by displaying its help menu: pyrit -h Use code with caution. Copied to clipboard

If successful, the terminal will display the version information (e.g., Pyrit 0.5.1) and a list of available options. Optional: Troubleshooting

Missing Python 2: If python2 is not installed, use sudo apt install python2.

Permission Denied: Ensure you use sudo for the final install step.

Existing Versions: If you have an old, broken version of Pyrit, remove it first with sudo apt remove --purge pyrit before building from source. Pyrit shines at precomputing Pairwise Master Keys: pyrit

Do you also need help setting up GPU acceleration (like CUDA or OpenCL) for Pyrit to speed up your cracking benchmarks? Pyrit no longer working Kali Linux Rolling #589 - GitHub

Installing Pyrit on modern Kali Linux requires manual compilation from source, as it is no longer available in the default repositories and relies on Python 2. Pyrit is a powerful tool for pre-computing WPA/WPA2-PSK authentication phases to speed up password cracking. Step-by-Step Installation Guide 1. Update System and Install Dependencies

First, ensure your system is up-to-date and install the necessary libraries for building Python 2 applications.

sudo apt-get update sudo apt-get install git python2-dev libssl-dev zlib1g-dev libpcap-dev -y Use code with caution. Copied to clipboard 2. Clone the Pyrit Source Code

Download the latest source from the active GitHub repository maintained by the community. git clone https://github.com/JPaulMora/Pyrit.git cd Pyrit Use code with caution. Copied to clipboard 3. Build and Install Pyrit Compile the main module using Python 2. sudo python2 setup.py build sudo python2 setup.py install Use code with caution. Copied to clipboard 4. Verify the Installation

Check if Pyrit is installed correctly by listing the available computing cores. pyrit list_cores Use code with caution. Copied to clipboard

You should see a list of your CPU cores. If you have an NVIDIA or AMD GPU, additional setup for CUDA or OpenCL is required to unlock GPU acceleration. Optional: Modern "PyRIT" (Microsoft Tool)

If you are looking for Microsoft's Python Risk Identification Tool (PyRIT) for AI red-teaming, the installation is different and uses Python 3.8+: Clone: git clone https://github.com/Azure/PyRIT.git Setup: Use a virtual environment and install via pip: Once installed, you can benchmark your system to

python3 -m venv pyrit-env source pyrit-env/bin/activate pip install -r requirements.txt pip install -e . Use code with caution. Copied to clipboard

Important Note: Traditional Pyrit (for Wi-Fi) is an older tool; many users now prefer Hashcat for GPU-accelerated WPA cracking because it supports modern drivers and hardware out of the box.

Here’s a professional yet easy-to-follow write-up for installing Pyrit on Kali Linux.


Pyrit is available in the Kali Linux repository, making it easy to install. Run the following command to install Pyrit:

sudo apt-get install pyrit

| Problem | Solution | |---------|----------| | error: command 'x86_64-linux-gnu-gcc' failed | Install python3-dev and build-essential | | OpenCL devices not found | Run sudo apt install clinfo && clinfo to debug | | Permission errors | Use sudo or add your user to sudo group | | No module named 'scipy' | Install with pip3 install scipy (optional dependency) |


Before beginning, update your system repositories and install the necessary dependencies. Open your terminal and run:

sudo apt update
sudo apt install libssl-dev python2-dev python2 libpcap-dev build-essential

Pyrit is a powerful tool for WPA/WPA2 PMK cracking, but its installation in modern Kali Linux requires manual compilation from GitHub due to Python 2 deprecation and library changes. The recommended approach is Method 2 (GitHub source installation) for full functionality, including GPU acceleration. If all else fails, Docker provides a reliable fallback.

Final Recommendation:
Use git clone https://github.com/JPaulMora/Pyrit.git followed by sudo python3 setup.py install. Always benchmark after installation to confirm GPU/CPU detection.