Add dislocker-recovery tool to extract recovery passwords#353
Add dislocker-recovery tool to extract recovery passwords#353cwerling wants to merge 2 commits intoAorimn:masterfrom
Conversation
Systems like Ubuntu 24.04 ship mbedTLS without CMake config files, causing find_package to fail. This adds a custom find module that locates mbedTLS on common Linux paths and creates imported targets. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
Sample output: |
|
Hey there, why not!? Thanks for this! Are you aware that once you have one of the recovery mechanism, one can use it to recover the recovery password and/or key (cf the comment here)? |
After successful decryption with any method (user password, BEK file, etc.), the -R/--show-recovery flag extracts and displays the BitLocker recovery password from the VMK. This implements the functionality suggested in the NOTE comment at src/accesses/accesses.c - using the VMK to recover other keys. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
Hey @Aorimn, thanks for the friendly check! This makes sense conceptually! I told Claude to throw away the extra CLI entrypoint (dislocker-recovery) and it instead implemented it where your comment was and added a command line option for it. I was only able to test compilation on a Ubuntu 24.04 Docker container on my Mac, so this definitely needs to be tested on a Linux system with some Bitlocker-encrypted drive attached. Can do that tomorrow. Cheers! |
|
Wow, that's quite awesome! |
|
Crazy times. Also, after sending Claude Code the link to your first PR comment, it replied pretty accurately :D Sorry for the off topic. Will send an update once I tested this tomorrow. |
Hi there,
I needed to get from a valid VMK to the accompanying recovery key (so I'd be able to boot into the live Windows environment). This was discussed in #294 and I asked Claude Code for help to implement it.
I decided to make it a separate binary as I didn't want dislocker-metadata to handle decryption stuff, but also found it unfitting for the other entrypoints.
Since I don't know if vibe-coded, but tested code is welcome, I'm cautiously advertising this to be merged. I also made some modifications to the cmake configs so I could compile it on both Ubuntu 24.04 and a recent Fedora.
I'm definitely open for any changes if needed. If you have a strict no-AI policy, feel free to discard it.