Commit Graph
6 Commits
Author SHA1 Message Date
Justin BollingerandClaude Opus 4.8 62a83699ac test: fix hate_path leak causing flaky test_main_pcfg
hate_crack.main is imported once and shared for the whole pytest
session, so any test that mutates its module globals without restoring
them leaks into every later test. test_markov_e2e assigned
main.hate_path / main.hcatHcstat2genBin directly (and before its skip
check, so it leaked even when skipped). test_main_pcfg's
test_builds_expected_subprocess reads the ambient hate_path to locate
pcfg_guesser.py and bails early when it's missing, so a leaked value
made it intermittently fail at captured_calls[0] (IndexError).

- test_markov_e2e: use monkeypatch.setattr so the globals auto-restore.
- test_main_pcfg: pin hate_path to a tmp dir containing a stub
  pcfg_guesser.py, making the test hermetic and independent of both the
  real pcfg_cracker submodule checkout and any leaked global state.

Full suite passes 3x consecutively; previously flaky.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-01 16:30:38 -04:00
Justin Bollinger 629ca85023 fix(pcfg): catch OSError on cache replace; tighten exception-restore test 2026-05-04 09:06:31 -04:00
Justin BollingerandClaude Sonnet 4.6 1718d55759 feat(pcfg): add hcatPrinceLing attack (mode B — cached wordlist via prince_ling, delegates to hcatPrince)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-04 09:04:15 -04:00
Justin Bollinger 2ee0123b00 test(pcfg): tighten hcatPCFG test — patch globals, assert stdin pipe, drop unused 2026-05-04 09:01:57 -04:00
Justin Bollinger e7410e8404 fix(pcfg): revert generate_session_id signature change, patch in test instead 2026-05-04 08:56:32 -04:00
Justin BollingerandClaude Sonnet 4.6 61ee3b50d7 feat(pcfg): add hcatPCFG attack (mode A — pcfg_guesser piped to hashcat)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-04 08:53:12 -04:00