mirror of
https://github.com/openwall/john.git
synced 2026-12-03 18:45:21 +07:00
[GH-ISSUE #1758] Intrinsics: Improve reversing of steps for SHA-2 #1166
Labels
No labels
bug
core branch
documentation
enhancement
enhancement
fixed - pending verify
fuzz bug
good first issue
invalid
invalid
maintenance/cleanup
new cracking mode
new format
new tool
non-trivial
notes/external issues
portability
question
RFC / discussion
testing
WONTFIX
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
openwall/john#1166
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @magnumripper on GitHub (Sep 13, 2015).
Original GitHub issue: https://github.com/openwall/john/issues/1758
Originally assigned to: @magnumripper on GitHub.
I think last three steps can be reversed with no pain at all for all SHA-2 formats.
@jfoug commented on GitHub (Sep 13, 2015):
But the only reason to do this, is on raw (or single iteration) formats. Making this change on something with 1000 (or 100000) iterations is pointless, and the side effects due to a .00001% improvement are not worth it. Side effects are things such as my code to find casing failures. This was not even dreamed about until just a couple days ago. But the extra code, and changes in debuggability certainly are other concerns. Yes, WHEN it makes a difference, then the side effects are certainly justified. BUT where there is absolutely no noticeable improvements in performance, we should not be doing the reversing IMHO. I would think anything past about 2 or 3 crypt iterations is pointless.
But for single limb hashes (raw, simple salted, etc), bring it on. I was pretty impressed with speed gains on the MD[45] you did. If sha-2 formats can also gain, then great!
@ghost commented on GitHub (Sep 14, 2015):
@magnumripper commented on GitHub (Sep 14, 2015):
Yes, obviously. Single-iteration formats, salted or not.
For SHA-2, just skipping last three steps should be a 4% gain. If you don't see it, that's probably a hint something else can be improved.
@ghost commented on GitHub (Sep 16, 2015):
I (kind of) disagree. Disclaimer: I need a computer to get the real numbers, but I hope the main point is clear:
Even is this situation, 4% gain is not possible any more. Ok, using a CPU it is.
@magnumripper commented on GitHub (Sep 16, 2015):
Sure but that is a strange point of view. Any boost is good. Solar's recent work with loading 29M hashes looked silly at times (hey guys I saved 300 ms out of 49 seconds) but in the end he saved a whole lot of seconds.
@ghost commented on GitHub (Sep 16, 2015):
I'm not saying it is a bad thing. I'm saying: on a GPU the gain was disappointing.
BTW: the reversing will be back (but not for mask mode where a full comparison is done inside GPU).
@magnumripper commented on GitHub (Sep 26, 2015):
As of
72af172we reverse seven steps for SHA-256 for another 3-4% boost, and we'll soon do the same for SHA-512. As far as I understand we can't do it for SHA-224/384, they'll be stuck at three because of unknown data when reversing.The raw boost in the SHA function alone should be about 10.5% for SHA-256 and 8.5% for SHA-512 (compared to no reversing at all).
@magnumripper commented on GitHub (Sep 26, 2015):
Reopening for seven steps of SHA-512
@magnumripper commented on GitHub (Oct 8, 2015):
Implemented in
a73a7742and for MSSQL12 in409fa047