openwall / openwall/john

pcap2john.py: Add support for extracting NTLMv2 hashes

Open
#4,212 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement portability
Dominant language
C
Stars
13.6k
Forks
2.6k
PR merge metrics
No merged PRs in 30d

Description

Description

Feature request. Add support for NTLMv2 in the pcap2john.py script.

Steps to reproduce
  • Start recording pcap
  • Mount cifs filesystem (smb2)
  • Stop recording.
  • Run pcap2john.py on the recorded pcap. Nothing extracted.

It is possible to open the pcap in wireshark and extract it manually using the method described here:

https://research.801labs.org/cracking-an-ntlmv2-hash/

But it would be nice if pcap2john could do it too.

System configuration

Tried with python2.7 and dpkt/scapy installed through pip.

Also, a separate issue but it might be fixed at the same time. The pcap2john.py script only works with python2. It should be fixed so it works with python3 and python2. New distributions have python3 as default.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with pcap2john.py and reproduce the SMB2/CIFS capture described in the issue, comparing its output with the Wireshark extraction method linked in the report. Review the existing dpkt/scapy handling and Python 2 compatibility before defining the NTLMv2 extraction path. Done means the script extracts NTLMv2 hashes from the reported pcap and works under Python 3 as well as Python 2.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, security
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.