All Projects → PaperMtn → Lil Pwny

PaperMtn / Lil Pwny

Licence: gpl-3.0
Fast, offline auditing of Active Directory passwords using Python.

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Lil Pwny

Passpwn
See if your passwords in pass has been breached.
Stars: ✭ 130 (+11.11%)
Mutual labels:  haveibeenpwned, password-safety
Firepwned
🙏 Checks Firefox saved passwords against known data leaks using the Have I Been Pwned API.
Stars: ✭ 69 (-41.03%)
Mutual labels:  haveibeenpwned, password-safety
laravel-pwned-passwords
Simple Laravel validation rule that allows you to prevent or limit the re-use of passwords that are known to be pwned (unsafe). Based on TroyHunt's Have I Been Pwned (https://haveibeenpwned.com)
Stars: ✭ 67 (-42.74%)
Mutual labels:  password-safety, haveibeenpwned
Password Leak
A library to check for compromised passwords
Stars: ✭ 92 (-21.37%)
Mutual labels:  haveibeenpwned, password-safety
haveibeenpwned4j
The ultimate Java library for Troy Hunt's ';-- Have I Been Pwned (v3).
Stars: ✭ 13 (-88.89%)
Mutual labels:  password-safety, haveibeenpwned
Passmaker
可以自定义规则的密码字典生成器,支持图形界面 A password-generator that base on the rules that you specified
Stars: ✭ 363 (+210.26%)
Mutual labels:  password-safety
Azure password harvesting
Plaintext Password harvesting from Azure Windows VMs
Stars: ✭ 61 (-47.86%)
Mutual labels:  password-safety
Bewgor
Bull's Eye Wordlist Generator - Does your password rely on predictable patterns of accessible info?
Stars: ✭ 333 (+184.62%)
Mutual labels:  password-safety
Pwned
An easy, Ruby way to use the Pwned Passwords API.
Stars: ✭ 290 (+147.86%)
Mutual labels:  haveibeenpwned
Fugacious
OSSSM (awesome). Open source short-term secure messaging
Stars: ✭ 100 (-14.53%)
Mutual labels:  password-safety
Pwned Passwords
🔐Go client library for checking values against compromised HIBP Pwned Passwords
Stars: ✭ 81 (-30.77%)
Mutual labels:  password-safety
Probable Wordlists
Version 2 is live! Wordlists sorted by probability originally created for password generation and testing - make sure your passwords aren't popular!
Stars: ✭ 7,312 (+6149.57%)
Mutual labels:  password-safety
Spicypass
A light-weight password manager with a focus on simplicity and security
Stars: ✭ 367 (+213.68%)
Mutual labels:  password-safety
Kaonashi
Wordlist, rules and masks from Kaonashi project (RootedCON 2019)
Stars: ✭ 353 (+201.71%)
Mutual labels:  password-safety
Pwnedornot
OSINT Tool for Finding Passwords of Compromised Email Addresses
Stars: ✭ 888 (+658.97%)
Mutual labels:  haveibeenpwned
Haveibeenpwned Zxcvbn Lambda Api
Deploy your own secure API to estimate password strength and check haveibeenpwned for known matches - HTTPS by force, server not required, fire and brimstone sold separately 🔥
Stars: ✭ 57 (-51.28%)
Mutual labels:  haveibeenpwned
Dumb Passwords
Don't let your user be a victim of their own action
Stars: ✭ 77 (-34.19%)
Mutual labels:  password-safety
Vue Password Strength Meter
🔐 Password strength meter based on zxcvbn in vue.js
Stars: ✭ 510 (+335.9%)
Mutual labels:  password-safety
Passwordpusher
🔐 PasswordPusher is an application to securely communicate passwords over the web. Passwords automatically expire after a certain number of views and/or time has passed.
Stars: ✭ 484 (+313.68%)
Mutual labels:  password-safety
Socialpwned
SocialPwned is an OSINT tool that allows to get the emails, from a target, published in social networks such as Instagram, Linkedin and Twitter to find possible credentials leaks in PwnDB.
Stars: ✭ 104 (-11.11%)
Mutual labels:  haveibeenpwned

Lil Pwny

Python 2.7 and 3 compatible PyPI version License: MIT

Fast, offline auditing of Active Directory passwords using Python.

About Lil Pwny

Lil Pwny is a Python application to perform an offline audit of NTLM hashes of users' passwords, recovered from Active Directory, against known compromised passwords from Have I Been Pwned. Results will be output in JSON format containing the username, matching hash (can be obfuscated), and how many times the matching password has been seen in HIBP

There are also additional features:

  • Ability to provide a list of your own custom passwords to check AD users against. This allows you to check user passwords against passwords relevant to your organisation that you suspect people might be using. These are NTLM hashed, and AD hashes are then compared with this as well as the HIBP hashes.
  • Return a list of accounts using the same passwords. Useful for finding users using the same password for their administrative and standard accounts.
  • Obfuscate hashes in output, for if you don't want to handle or store live user NTLM hashes.

More information about Lil Pwny can be found on my blog

Resources

This application has been developed to make the most of multiprocessing in Python, with the aim of it working as fast as possible on consumer level hardware.

Because it uses multiprocessing, the more cores you have available, the faster Lil Pwny should run. I have still had very good results with a low number of logical cores:

  • Test env of ~8500 AD accounts and HIBP list of 613,584,246 hashes:
    • 6 logical cores - 0:05:57.640813
    • 12 logical cores - 0:04:28.579201

Output

Lil Pwny will output results as JSON format either to stdout or to file:

{"localtime": "2021-00-00 00:00:00,000", "level": "NOTIFY", "source": "Lil Pwny", "match_type": "hibp", "detection_data": {"username": "RICKON.STARK", "hash": "0C02C50B2B08F2979DFDE12EDA472FC1", "matches_in_hibp": "24230577", "obfuscated": "True"}}

This JSON formatted logging can be easily ingested in to a SIEM or other log analysis tool, and can be fed to other scripts or platforms for automated resolution actions.

Installation

Install via pip

pip install lil-pwny

Usage

Lil-pwny will be installed as a global command, use as follows:

usage: lil-pwny [-h] -hibp HIBP [-c CUSTOM] -ad AD_HASHES [-d]
                   [-output {file,stdout}] [-o]

optional arguments:
  -h, --help            show this help message and exit
  -hibp HIBP, --hibp-path HIBP
                        The HIBP .txt file of NTLM hashes
  -c CUSTOM, --custom CUSTOM
                        .txt file containing additional custom passwords to
                        check for
  -ad AD_HASHES, --ad-hashes AD_HASHES
                        The NTLM hashes from of AD users
  -d, --duplicates      Output a list of duplicate password users
  -output {file,stdout}, --output {file,stdout}
                        Where to send results
  -o, --obfuscate       Obfuscate hashes from discovered matches by hashing
                        with a random salt

Example:

lil-pwny -hibp ~/hibp_hashes.txt -ad ~/ad_user_hashes.txt -c ~/custom_passwords.txt -output stdout -do

Getting input files

Step 1: Get an IFM AD database dump

On a domain controller use ntdsutil to generate an IFM dump of your AD domain. Run the following in an elevated PowerShell window:

ntdsutil
activate instance ntds
ifm
create full **output path**

Step 2: Recover NTLM hashes from this output

To recover the NTLM hashes from the AD IFM data, the Powershell module DSInternals is required.

Once installed, use the SYSTEM hive in the IFM data to recover the hashes in the format usernme:hash and save them to the file ad_ntlm_hashes.txt

$bootKey = Get-BootKey -SystemHivePath '.\registry\SYSTEM'
Get-ADDBAccount -All -DBPath '.\Active Directory\ntds.dit' -BootKey $bootKey | Format-Custom -View HashcatNT | Out-File ad_ntlm_hashes.txt -Encoding ASCII

Step 3: Download the latest HIBP hash file

The file can be downloaded from here

The latest version of the hash file contains around 613 million hashes.

Resources

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].