Skip to content

Commit

Permalink
Fix README and sort row estimate
Browse files Browse the repository at this point in the history
  • Loading branch information
junderw committed Oct 25, 2023
1 parent d19bc25 commit b314a11
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "hibp_downloader"
version = "1.0.2"
version = "1.0.3"
license = "MIT"
authors = [
"Jonathan Underwood <[email protected]>"
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ Commands:
Options:
--workers <WORKERS> The number of workers to use for requests [default: NUM_CPU]
--multiplier <MULTIPLIER> The number of requests per worker [default: 20]
--multiplier <MULTIPLIER> The number of requests per worker [default: 128/NUM_CPU]
-n, --ntlm Download NTLM hashes instead of SHA1 hashes
--output-file <OUTPUT_FILE> The file where the output will be written.
This file will be sorted by hash. [default: ./hibp_password_hashes.txt]
Expand Down
4 changes: 2 additions & 2 deletions src/sort/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ pub fn run_sort(input: &Path, output: &Path, temp_dir: &Path) -> anyhow::Result<
assert!(len == 32 || len == 40);
len
};
// colon + average of 5 length number (max 8, min 1) + new line
let row_size = hash_size + 7;
// colon + average of 4 length number (max 8, min 1) + new line
let row_size = hash_size + 6;
let rows_in_file = input_byte_size / row_size as u64;

// This is a rough estimate.
Expand Down

0 comments on commit b314a11

Please sign in to comment.