Skip to content

Instantly share code, notes, and snippets.

@ramuta
ramuta / sudo_brute_force.py
Last active April 8, 2024 05:12
A Python script to brute force the sudo password of a current user.
# Author: Matej Ramuta
# How to use this script:
# 1. You need to have a wordlist file, something like rockyou.txt
# 2. Make sure you have Python 3 installed. Try this with "python --version" command. Also check "python3 --version"
# 3. Run the script like this: python sudo_brute_force.py passwords.txt
import os
import sys
if len(sys.argv) == 1: