Horcrux: Split your file into encrypted fragments
I was just thinking about something like this problem.<p>At $work, we use multi-signature signing to move cryptocurrency around, so that at least N of M officers of the company need to sign, to prove that &quot;the company&quot; actually intends a movement of funds to happen. This ensures that no single officer can embezzle funds; and it also ensures that an attacker would have to do some kind of multi-target simultaneous coordinated rubber-hose attack (rather than just waiting to kidnap one of us when we go on vacation) to get access to the funds.<p>I was trying to think of a way to extend that kind of security to the encryption of data — specifically the encryption of low-level root-account passwords (like an AWS account&#x27;s root password). Shamir&#x27;s Secret Sharing is the obvious first step... but you&#x27;d also then want two additional properties:<p>1. the decrypted secret should not be held even temporarily by any of the parties, but rather should be held by — and used &quot;through&quot; — a neutral system, so that the secret is reusable rather than needing to be burned the first time it&#x27;s revealed<p>2. the neutral system — despite being likely owned by a third party! — should have no ability to exfiltrate the password into the hands of the third party.<p>I <i>think</i> this can be workable in the specific case of wanting to use the root password as an HMAC, by doing SSS decryption inside a single-shot non-durable abstract machine with homomorphically-encrypted memory, wrapped in a network daemon: the network daemon spins up a copy of the abstract machine; receives each SSS key split from its owner, feeding each as it receives it directly into the abstract machine; the abstract machine, after receiving sufficient key splits, signals to the daemon that it is now &quot;empowered&quot; to sign; and the daemon can then use the abstract machine to HMAC arbitrary plaintexts sent to it, until it exits, and the abstract machine&#x27;s state is lost.<p>The real trick, though, would be making this work for HTTP Basic Auth over TLS, by delegating the generation of exactly one TLS frame — the one containing the Authorization header — to the abstract machine; where the network daemon would then act as an HTTP proxy, inserting this Authentication header into requests made through it. Having something like this could really improve security around the use of a lot of sensitive control-plane APIs!<p>---<p>Of course, in a corporate context, you probably <i>have</i> a third party you can trust with the plaintext — e.g. an Enterprise Password Manager service — so you can relax property 2. In such a case, you don&#x27;t need a fancy abstract machine; you can just ask said service to build a feature allowing secrets to be configured to require N-of-M confirmations by ACLed team-members to unlock them; and to build another feature for &quot;opaque secrets&quot; that are never revealed to anyone, but instead are injected into an HTTP Authorization Proxy that the Enterprise Password Manager service spin up themselves on their backend.<p>But it&#x27;s still fun to think about the case where your secret is <i>so</i> secret that you need to hide the plaintext from literally everyone but your co-conspiriators. :)