From: Frank Steinmetzger <Warp_7@gmx.de>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] Encrypting a hard drive's data. Best method.
Date: Sat, 6 Jun 2020 17:07:11 +0200 [thread overview]
Message-ID: <20200606150711.GA274766@kern> (raw)
In-Reply-To: <ddcf7e41-ef39-eae8-ba36-82efc057a1ee@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 3559 bytes --]
On Fri, Jun 05, 2020 at 11:37:23PM -0500, Dale wrote:
> Howdy,
>
> I think I got a old 3TB hard drive to work. After dd'ing it, redoing
> partitions and such, it seems to be working. Right now, I'm copying a
> bunch of data to it to see how it holds up. Oh, it's a PMR drive too.
> lol Once I'm pretty sure it is alive and working well, I want to play
> with encryption. At some point, I plan to encrypt /home. I found a bit
> of info with startpage but some is dated. This is one link that seems
> to be from this year, at least updated this year.
Encryption is a means to protect against adversaries, but in my case I
mostly want to protect from incidental access. My top “use” cases:
- I need to send in a broken disk for service/replacement
- $DEVICE is stolen and I dont’t want the thief to access my personal stuff
- the device needs to be serviced, but has its storage soldered on
- protect from recovery on flash storage
I’ve been running full-disk encryption with LUKS/LVM for some years now on
my laptop’s SSD. I used Sakaki’s scripts to set up the kernel and initrd.
The encryption password is entered during the boot process while still in
the initrd phase. I don’t know of the current status of Sakaki’s stuff
though (I must admit I moved away from Gentoo because portage took to much
time on the laptop).
On my main PC I used to have ~ on a hard disk and / on an SSD. So I left /
unencrypted and symlinked sensitive files such as wpa_supplicant.conf and
database files onto a directory beneath /home. Since decryption is done
early at boot, there is no race condition. By now I upgraded the SSD and
have both / and ~ on it, but I kept the scheme out of laziness.
A week ago I got me and myself a used Surface Go (a little X86 tablet) which
only has a small SSD soldered onto the board. There is no way to access or
replace it. I didn’t want to use the same approach as with the laptop,
because I wanted to be able to boot without a keyboard. This meant that PW
entry at early boot was no option because there is no touch support at this
stage. So I researched a little towards decryption at login. Ext4-internal
encryption was a strong contender, because it allowed me to decrypt ~ on
login, while still using a shared partitions for / and ~, which would give
me more flexibility on the constrained SSD. It also encrypts filenames, but
not access times (which I was OK with). Eventually though, I decided to go
for more encapsulation and put ~ on a separate partition again. I set it up
with LUKS and auto-mount it on login with pam_mount.
On a performance not: the Surface Go has an NVME SSD and hdparm -t varies
wildly between 220 and 640 MB/s. OTOH, cryptsetup benchark resulted in 1330
MiB/s for aes-cbc with a 128 bit key. Aes-xts was slower, but once I
disabled all kernel mitigations¹, its throughput went up by more than 40 %
and also reached 1300 MiB/s. And this is for the meagre Pentium Gold
processor. So no worries in that department.
¹ Many of those vulnerabilities are about violating memory boundaries, which
is most relevant for server operators and securing their users from each
other. Thus, I don’t care about those on my personal machines and rather
have the original performance. Exploits need to get *on* my machines first
before they can snoop in my memory.
--
Gruß | Greetings | Qapla’
Please do not share anything from, with or about me on any social network.
I hate being bi-polar. It’s fantastic!
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2020-06-07 16:44 UTC|newest]
Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-06 4:37 [gentoo-user] Encrypting a hard drive's data. Best method Dale
2020-06-06 7:14 ` J. Roeleveld
2020-06-06 7:16 ` J. Roeleveld
2020-06-06 7:49 ` Dale
2020-06-06 10:32 ` Michael
2020-06-06 14:14 ` antlists
2020-06-06 11:05 ` Rich Freeman
2020-06-06 13:31 ` Victor Ivanov
2020-06-06 13:57 ` antlists
2020-06-06 14:10 ` Rich Freeman
2020-06-06 15:05 ` Jack
2020-06-06 14:18 ` antlists
2020-06-06 15:07 ` Dale
2020-06-06 19:02 ` J. Roeleveld
2020-06-06 14:07 ` Victor Ivanov
2020-06-06 18:51 ` Rich Freeman
2020-06-06 19:38 ` Victor Ivanov
2020-06-06 20:12 ` Rich Freeman
2020-06-07 0:47 ` Victor Ivanov
2020-06-07 1:04 ` Rich Freeman
2020-06-07 1:50 ` Dale
2020-06-07 8:08 ` Dale
2020-06-07 9:07 ` antlists
2020-06-07 18:23 ` antlists
2020-06-09 20:24 ` Dale
2020-06-09 21:30 ` [gentoo-user] Encrypting a hard drive's data. Best method. PICS attached Dale
2020-06-07 10:33 ` [gentoo-user] Encrypting a hard drive's data. Best method Rich Freeman
2020-06-07 11:52 ` Victor Ivanov
2020-06-07 12:43 ` Victor Ivanov
2020-06-07 7:37 ` antlists
2020-06-06 15:07 ` Frank Steinmetzger [this message]
2020-06-06 20:21 ` Sebastiaan L. Zoutendijk
2020-06-07 1:54 ` Dale
2020-06-10 6:59 ` Dale
2020-06-10 9:52 ` Michael
2020-06-10 21:02 ` Dale
2020-06-10 13:37 ` Victor Ivanov
2020-06-10 20:52 ` Dale
2020-06-11 21:51 ` Victor Ivanov
2020-06-11 22:17 ` Dale
2020-06-11 23:08 ` Victor Ivanov
2020-06-12 2:00 ` Dale
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200606150711.GA274766@kern \
--to=warp_7@gmx.de \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox