For my private keys, I export them into PEM format, convert that into a QR code, and print them out. This goes in my fire-resistant Fort Knox vault [1] for safe keeping. The vault is bolted to the cement floor and cannot be carted away.
I use intermediate certs for my internal CA and do keep those private keys online for quick and easy generation of new certs but the root cert private key only exists in physical form under my control. It's a bit of a pain to convert the root key back into digital form but I only have to do this every couple of years when the intermediate cert expires.
I got into a habit of writing shell scripts for every certificate related task to make it easier. I use the dialog(1) utility to prompt me for input when that's needed. If things are easy, you're more likely to do them.
How do you check that your printer isn't secretly storing your key somewhere? I've looked for open source/open hardware printers some time ago, unsuccessfully. I've written my main key down on paper by hand as a backup, but it's a tedious task.
As you mentioned fire-resistance, do you also use some sort of fire resistant paper? Because I don't think anything in made of paper would survive an actual fire.
> I've looked for open source/open hardware printers some time ago
You want a pen plotter. Or its cheaper, more expensive cousin, the Axidraw.
> As you mentioned fire-resistance, do you also use some sort of fire resistant paper? Because I don't think anything in made of paper would survive an actual fire.
Actually there are document safes with built-in insulation which will keep regular paper documents safe for time X under fire conditions Y (it's some EU standard classification). Certain ways of mounting safes makes them intrinsically fire-safe(r) as well.
Vintage pen plotters (or X-Y recorders) are essentially zero-price items and tend to be built like actual tanks. The ones you can buy today (and afford) are way more expensive than them, yet cheaper (in quality). However, vintage pen plotters tend to not have USB plugs.
Speaking of plotters, consider engraving the QR code in aluminum instead of having it on paper. If there's any hacker space nearby where you live they might have CNC equipment that they will let you borrow and instruct you how to use.
> I've written my main key down on paper by hand as a backup, but it's a tedious task.
Elliptic curves are nice because they allow short keys, for example curve25519 uses 32 byte keys that are pretty reasonable to copy manually (44 base64 chars or 64 hexs).
Meaning you could use PBKDF2 of your favorite passphrase as your private key, then keep it in organic memory.
Personally, I would love to see a strategy for generating a private from an analog picture.. But I don't see a good way to do it reliably.. Maybe one could generate it from error correction bits in a QR code.
I'm not sure you can use a KDF because it requires a salt.
I'm working on a blog post on deterministic passwords (i.e. not keys for ECC), but I guess that if you really want determinism you can do something similar, maybe sha3.512 and "cut" a 256-bit ECC key.
> Personally, I would love to see a strategy for generating a private from an analog picture.. But I don't see a good way to do it reliably.. Maybe one could generate it from error correction bits in a QR code
Not clear exactly what you meant, but but deriving a key from a photograph shouldn't be that difficult. A good perceptual hash should work, maybe some preprocessing is needed (straighten/crop/normalize/resize). It helps that the amount of data in an image is absolutely massive compared to typical key size.
Prime number generation is typically done like this. Pick a random number, then add 2 until you get a prime.
So you can do something similar. Pick a deterministically generated bit string, and use as key the next prime number (you need to do it twice, for p and q).
You certainly get less security and I unfortunately don't have any reference to quantify that.
Even if there is, such a key would be much less safe (assuming the attacker knew the algorithm, which must be assumed, otherwise why keep the key in a safe?)
Of course, because that drastically reduces the key space.
Before: 2^2048, After: 256^20 = 2^160 (when using a 20 key password. Obviously you could use looong random generated passphrases, but then you could just base64encode your key?)
What's the point of encrypting it? It seems like just another thing to mess up, and much more likely that you'll forget the password versus someone breaks into your house, goes into your safe, and knows what a private key is.
What's the point of storing data inside a combination safe? Isn't that equivalent to encrypting the data with the combination to the safe and storing it wherever?
Love that vault suggestion, but for a lot of folks, a safety deposit box might be sufficient (with your own enclosure within it using tamper evident stickers).
Having moved 5+ times in the last decade, I'd dread thinking about having to move that safe you linked to.
We are a military family so we typically move every two or three years. My vault weighs about 900 pounds but the movers never have any trouble with it. In fact, the guy that installed it was an old man driving a pick up truck. He used an amazing motorized dolly that had no problem pushing it around and could climb stairs.
My vault is bolted 4" into reinforced concrete using bolts that are only accessible from inside the vault. Unless you have the combination to open the vault first, you're going to have to rip out the slab to get this thing out of my garage.
For your PEM formatted keys, why a vault? Don't vaults just advertise "what is in here is SUPER important"? Police love vaults. Wouldn't it be safer on a sd hiding case in a few places (mom's house in attic, one under your oven?)
I should have explained this better: the vault is not to keep the private key safe from home intruders, it’s to keep the key safe from loss and fire and anyone that might compromise my CA machine. It acts as an air gap of sorts.
Once in a blue moon when the intermediate cert expires, I pull out the QR code and scan it and convert it to a PEM on a burner laptop, VM, or phone. There I generate a new intermediate and securely delete the root PEM file and put the QR back in the vault. Then I copy the inermediate off the burner machine and go about my business.
Glue the QR code onto an old boarding pass and keep it in your photo album... then stick a broken yubikey into your grandmothers coffin for plausible deniability.
- the latter is a joke ofcourse! :)
For plausible deniability it's a lot less controversial to mix a broken yubikey in concrete and cast it as pavement.
I have tried printing QR code of keys but with no success (the phone does not recognise the image) what do you use to generate the image that is sufficiently resolved to print and be functional ?
I use intermediate certs for my internal CA and do keep those private keys online for quick and easy generation of new certs but the root cert private key only exists in physical form under my control. It's a bit of a pain to convert the root key back into digital form but I only have to do this every couple of years when the intermediate cert expires.
I got into a habit of writing shell scripts for every certificate related task to make it easier. I use the dialog(1) utility to prompt me for input when that's needed. If things are easy, you're more likely to do them.
[1] https://www.ftknox.com/vaults/legend-vault/