Other bdemount not working, attempts to read less than block size

I'm trying to use bdemount from the libbde package to mount a bitlocker encrypted drive.

It fails with:


# bdemount /dev/da0p1 /mnt
bdemount 20221031

Unable to open source volume
libcfile_file_read_buffer_with_error_code: unable to read from file with error: Invalid argument
[...]


The problem is while parsing the volume header it attempts to do a read for 64 bytes, which fails with EINVAL because it's not a multiple of the blocksize.


13712 bdemount CALL read(0x3,0x82067d280,0x40)
13712 bdemount RET read -1 errno 22 Invalid argument


Does anyone use bdemount successfully on FreeBSD and is there a way around this?

A "clever" workaround I found is to copy the whole raw disk:

# dd if=/dev/ada2p4 bs=4096 of=/tmp/mydisk
# bdemount /tmp/mydisk /mnt


Mounting the copied source then works because it's allowed to do the small read on a regular file.
Although that's not a great solution for a 4TB drive.
 
Back
Top