Remix.run Logo
Retr0id 5 hours ago

> If you're using off-the-shelf "hidden" encrypted volume schemes, you're not going to be evading state-level adversaries;

I kinda assumed this was a solved problem now, up to the information-theoretic limit. Just create a FAT32 fs (for example), put some boring decoy files on it, and then unmount it. Traverse the FAT to map which blocks are in-use vs not-in-use, and use the not-in-use ones to store your encrypted data in some arbitrary header-free indistinguishable-from-random format. The result should look just like someone had set up a FAT filesystem on top of a securely erased drive.

If anyone ever mounts and subsequently writes to the FAT volume they'll clobber your data - oh well.

The remaining issue is that you need some special software on the host to mount the hidden volume, which itself raises suspicions. This could be solved by bundling it with OSes by default.

ianburrell an hour ago | parent | next [-]

Instead of FAT32, use the flash drive mapping. Flash drive contain mapping from sectors to blocks. This is used to deal with flash erasure, wear leveling, and failures. Custom firmware could map the real filesystem to bad blocks.

Does the forensic software read the whole physical flash drive or just the logical one? They might if they want to get deleted files. Can they detect that there are lots of failures?

Retr0id an hour ago | parent [-]

You need the wear levelling system for actual wear leveling, otherwise the drive won't last very long. Competent forensic analysis can check the firmware and the physical flash contents, although most forensic analysis is not especially competent.

jandrese 4 hours ago | parent | prev | next [-]

Doesn't FAT have the concept of "badblocks" to handle the old days when sectors could randomly fail on drives and they had to work around it? It would only be slightly more suspicious but it would allow the drive to be mounted and used as a regular drive to avoid the even more suspicious unmounted volume issue. The data in the sectors would obviously be encrypted so it looks like random noise if someone does start poking around looking at it.

Retr0id 3 hours ago | parent [-]

It does, but it's extremely unusual for the feature to be in use on modern hardware.

I thought of a much simpler approach though. Personally, it's completely normal for my USB drives to contain some OS installer dd'd to the first few GB, and to be wiped with urandom between uses. The installer .iso is typically immutable and will never expand beyond its initial size. Rather than mess around with block mappings, I can just use last n GB as a hidden storage volume. dm-crypt "plain" mode is headerless and can be configured to start from some offset within the underlying block device.

The only giveaway here might be forensic examination of the drive's internal wear-leveling data.

pixl97 4 hours ago | parent | prev [-]

>This could be solved by bundling it with OSes by default.

Apple and Microsoft? I trust apple a bit more and MS none at all.

Linux is a bit different because the kernel is the OS, but only a small part of all its different packages. Also you'll have to watch it like a hawk because nation states will constantly try to compromise it.