[Swlug] mount disk image file with encryption
Mark Einon
mark.einon at gmail.com
Mon Nov 23 19:59:40 UTC 2020
Hi Bascule,
A little tip - the disk type is GPT so fdisk won't work, gparted or
gdisk will.
Best regards,
Mark
On Mon, 2020-11-23 at 19:28 +0000, bascule via Swlug wrote:
> i have a failing microsd card, i've made an image of it but i can't
> find the
> right arguments to access the contents of the image file.
>
> the card is adopted storage from an android phone and i have the key,
> using
> the physical card i can access it using:
> dmsetup create crypt1 --table "0 `blockdev --getsize /dev/sdf2` crypt
> aes-cbc-
> essiv:sha256 `cat key` 0 /dev/sdf2 0"
>
> and then mounting.
>
> but while fdisk sdcard_img shows:
> [root at mycroft bascule]# fdisk sdcard_img
>
> Welcome to fdisk (util-linux 2.33.2).
> Changes will remain in memory only, until you decide to write them.
> Be careful before using the write command.
>
>
> Command (m for help): p
> Disk sdcard_img: 119.8 GiB, 128579534848 bytes, 251131904 sectors
> Units: sectors of 1 * 512 = 512 bytes
> Sector size (logical/physical): 512 bytes / 512 bytes
> I/O size (minimum/optimal): 512 bytes / 512 bytes
> Disklabel type: gpt
> Disk identifier: B826F4C0-DC80-4670-A4A7-F99A7314FF9F
>
> Device Start End Sectors Size Type
> sdcard_img1 2048 34815 32768 16M unknown
> sdcard_img2 34816 251131870 251097055 119.7G unknown
>
>
> i don't know how to reference the 2nd 'partition' on the image file
> for the
> dmsetup command.
> since making the image file the card seems to be failing more and more
> so i
> wish to extract files from the image file
> can someone help me?
>
> bascule
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.lug.org.uk/pipermail/swlug/attachments/20201123/24814ebb/attachment.html>
More information about the Swlug
mailing list