mirror of
https://github.com/openwall/john.git
synced 2026-12-03 18:45:21 +07:00
[GH-ISSUE #985] Should dynamic formats store trailing salts that end in ' ' or '\t' converted to hex? #585
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#585
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 @frank-dittrich on GitHub (Jan 1, 2015).
Original GitHub issue: https://github.com/openwall/john/issues/985
We do have hex conversion of certain salts with problematic characters already, e.g. for salts that would otherwise contain ':' or '$'.
May be salts that end in a trailing space or horizontal tab character (or salts containing
' 'or'\t') should be converted into hex before storing in john.pot.Otherwise, those hashes will cause trouble if you try to verify the contents of a pot file.
Consider this line:
This is the result of cracking the first osc format self test hash.
When you run
and then either
or
you will not be able to verify that this particular hash has been cracked correctly.
The reason is that the loader will strip trailing spaces when loading the hashes:
@jfoug commented on GitHub (Jan 1, 2015):
You are probably very right here @frank-dittrich, and this has likely been a problem for a while.
-show lists it. rerun reads it and properly strips out the input for any follow up runs. But yes, you are right, cutting from pot should fail. However, I thought I was doing that already?? I guess I do not cut the hashes from the .pot file, just the passwords, and rerun to make sure that what was written into the .pot can actualiy crack hashes, BUT I think i still use original input hashes as test,, so the TS would not have seen this 'issue'.
The 'issue' is a bit contrived, but I think you are right, and it should be fixed, and this logic added to the set of 'dangerous' salts and turned into
HEXbefore putting into .pot.@jfoug commented on GitHub (Jan 1, 2015):
@frank-dittrich would you mind giving it a go at coding this? It really should not be 'too' hard to find. I think the function is named something like dynamic_remove_hex (or add hex, or something like that). Just look for HEX[$] and it should pop right up. It is in dynamic_utils.c and is function dynamic_FIX_SALT_TO_HEX()
@frank-dittrich commented on GitHub (Jan 2, 2015):
@jfoug done, see commit
github.com/magnumripper/JohnTheRipper@ec14e1fe2d.I guess I'll create a new issue for the --show=LEFT problem I just noticed (see the comment I added to my commit
ec14e1f.@jfoug commented on GitHub (Jan 2, 2015):
I think you are right, the show-left has probably been there forever. We have just not spotted it yet.
@frank-dittrich commented on GitHub (Jan 2, 2015):
The original issue has been fixed by
github.com/magnumripper/JohnTheRipper@ec14e1fe2d.There's a separate issue for the --show=LEFT problem: https://github.com/magnumripper/JohnTheRipper/issues/986
I'm closing this one.