mufeedvh / pdfrip

A multi-threaded PDF password cracking utility equipped with commonly encountered password format builders and dictionary attacks.
MIT License
589 stars 67 forks source link

Ensure we can bruteforce spans of dates instead of one year at a time. #13

Closed Pommaq closed 8 months ago

Pommaq commented 8 months ago

This addresses #12.

Pommaq commented 8 months ago

Running env LOG_LEVEL=info cargo run --release -- --filename examples/datetime-15012000.pdf date 1900 2000 does not successfully crack the PDF, while env LOG_LEVEL=info cargo run --release -- --filename examples/datetime-15012000.pdf date 1900 2001 succeeds despite this generator sending passwords inclusively. I suspect there is a bug somewhere else that will need to be investigated

Adding debug logging to the DateProducer next() function shows the correct password is being sent but not recognized.

 2023-12-03T21:34:13.151Z DEBUG pdfrip::core::production::dates > Sending 15012000 from DateProducer

This means there is a race condition somewhere. Likely in engine.rs.

mufeedvh commented 8 months ago

Thank you! Merging this right away! :raised_hands: