openwall / openwall/john

external hybrid mode needs 'pushed' fix_state handling

Open
#2,099 38 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

when doing hybrid external on top of wordlist, the 'fix state' logic called by crk_process_key was calling the crk_fix_state from wordlist.c, not the ext_hybrid_fix_state. This had two bad effects:

  1. ext_hybrid_fix_state was not being called as frequently as it should have been or in the right place
  2. wordlist's 'fix state' was being called too early, when the word was not yet complete, and in the case of an interruption, the 'restore' would resume at the next word, not the current one, skipping all the remaining permutations of hybrid external on that word.

I have attached a patch, and as a bonus, attached a hybrid 'leet' mode word rotator for your cracking pleasure. (i needed it for lc7, so here you go.)

p.patch.txt
hybridleet.zip

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 in crk_process_key and wordlist.c, then compare crk_fix_state with ext_hybrid_fix_state. Review the attached patch and verify that external hybrid uses its own fix-state handling at the correct point, while interruption restore resumes the current word's remaining permutations rather than skipping to the next word.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.