[GH-ISSUE #729] wpapcap2john: Do not output "unverified" entries when there are "verified" ones. #371

Closed
opened 2026-10-14 03:03:19 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @magnumripper on GitHub (Sep 1, 2014).
Original GitHub issue: https://github.com/openwall/john/issues/729

Example

$ ../run/wpapcap2john wpa-Induction.pcap 
wpa-Induction.pcap: Radiotap headers stripped

Key1/Key2 hit (unverified), for ESSID:Coherer (wpa-Induction.pcap)
Dumping key 1 at time:  5.650959 BSSID 00:0C:41:82:B2:55
Coherer:$WPAPSK$Coherer#..l/Uf7J..qHUXMunTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosMyXdNxfBZUAYmgKqeb6GBPxLiIZr56NtWTGR/Cp5ldAk61.5I0.Ec.2...........nTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosM.................................................................3X.I.E..1uk0.E..1uk2.E..1uk0....................................................................................................................................................................................../t.....U...8FWdk8OpPckhewBwt4MXYI:00-0d-93-82-36-3a:00-0c-41-82-b2-55:000c4182b255::WPA2:password not verified:wpa-Induction.pcap


Key2/Key3 hit (100% verified), for ESSID:Coherer (wpa-Induction.pcap)
Dumping key 3 at time:  5.655957 BSSID 00:0C:41:82:B2:55
Coherer:$WPAPSK$Coherer#..l/Uf7J..qHUXMunTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosMyXdNxfBZUAYmgKqeb6GBPxLiIZr56NtWTGR/Cp5ldAk61.5I0.Ec.2...........nTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosM.................................................................3X.I.E..1uk0.E..1uk2.E..1uk0....................................................................................................................................................................................../t.....U...8FWdk8OpPckhewBwt4MXYI:00-0d-93-82-36-3a:00-0c-41-82-b2-55:000c4182b255::WPA2:password verified:wpa-Induction.pcap

The file actually only contains one set of four EAPOL packets. The first, "unverified" entry is output when the second packet is seen, and the second, "verified" one is output when the third packet is seen. What we should do, but that requires two passes, is output the "unverified" entry only if we never see the third packet.

This is not much of a concern since JtR will remove dupes anyway. But it would be nice to get rid of them.

Originally created by @magnumripper on GitHub (Sep 1, 2014). Original GitHub issue: https://github.com/openwall/john/issues/729 Example ``` $ ../run/wpapcap2john wpa-Induction.pcap wpa-Induction.pcap: Radiotap headers stripped Key1/Key2 hit (unverified), for ESSID:Coherer (wpa-Induction.pcap) Dumping key 1 at time: 5.650959 BSSID 00:0C:41:82:B2:55 Coherer:$WPAPSK$Coherer#..l/Uf7J..qHUXMunTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosMyXdNxfBZUAYmgKqeb6GBPxLiIZr56NtWTGR/Cp5ldAk61.5I0.Ec.2...........nTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosM.................................................................3X.I.E..1uk0.E..1uk2.E..1uk0....................................................................................................................................................................................../t.....U...8FWdk8OpPckhewBwt4MXYI:00-0d-93-82-36-3a:00-0c-41-82-b2-55:000c4182b255::WPA2:password not verified:wpa-Induction.pcap Key2/Key3 hit (100% verified), for ESSID:Coherer (wpa-Induction.pcap) Dumping key 3 at time: 5.655957 BSSID 00:0C:41:82:B2:55 Coherer:$WPAPSK$Coherer#..l/Uf7J..qHUXMunTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosMyXdNxfBZUAYmgKqeb6GBPxLiIZr56NtWTGR/Cp5ldAk61.5I0.Ec.2...........nTE3nfbMWSwxv27Ua0XutIOrfRSuv9gOCIugIVGlosM.................................................................3X.I.E..1uk0.E..1uk2.E..1uk0....................................................................................................................................................................................../t.....U...8FWdk8OpPckhewBwt4MXYI:00-0d-93-82-36-3a:00-0c-41-82-b2-55:000c4182b255::WPA2:password verified:wpa-Induction.pcap ``` The file actually only contains one set of four EAPOL packets. The first, "unverified" entry is output when the second packet is seen, and the second, "verified" one is output when the third packet is seen. What we should do, but that requires two passes, is output the "unverified" entry only if we never see the third packet. This is not much of a concern since JtR will remove dupes anyway. But it would be nice to get rid of them.
bsakaguchi 2026-10-14 03:03:19 +07:00
Author
Owner

@jfoug commented on GitHub (Nov 26, 2014):

Fixed. I simply save off buffers for the unverified, then when I get a verified one, I remove the prior unverified (if found). Then when done with the file, any unverified hashes left, get output.

The order may be different, but result is that only verified hash pair is listed (if there are both), and no hashes are left unprinted.

<!-- gh-comment-id:64594809 --> @jfoug commented on GitHub (Nov 26, 2014): Fixed. I simply save off buffers for the unverified, then when I get a verified one, I remove the prior unverified (if found). Then when done with the file, any unverified hashes left, get output. The order may be different, but result is that only verified hash pair is listed (if there are both), and no hashes are left unprinted.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
openwall/john#371
No description provided.