Expand description
ยงOne-Time Pad
Brute force slog through all possible keys, parallelized as much as possible. An optimization
for part two is a quick method to convert u32
to 8 ASCII digits.
Structsยง
- Exclusive ๐Regular data structures need to be protected by a mutex.
- Shared ๐Atomics can be safely shared between threads.
Functionsยง
- check ๐Check for sequences of 3 or 5 consecutive matching digits.
- format_
string ๐Write the salt and integer index as ASCII characters. - generate_
pad ๐Find the first 64 keys that sastify the rules. - Hash each key once.
- Hash each key an additional 2016 times.
- to_
ascii ๐Quickly convert au32
to an array of 8 ASCII values. - worker ๐