197 points · by theafh · 6y ago · 88 comments
Reads article
Yup! Gosh, I can't wait for it to become remotely practical.
It's been a few years -- wow, almost a decade -- but I remember a paper that claimed to prove that "no fully homomorphic program can be written such that the secret key was guarded in all cases," i.e. it's theoretically possible to trick a FHE program into giving up its own key, unless your program is basically trivial.
It was one of those papers that you run across, then never see again, and wistfully wish you'd saved a reference to. Tantalizing idea, if true, but probably not true.
EDIT: I just went back to finish the article, and they linked to it: https://link.springer.com/chapter/10.1007/3-540-44647-8_1 Welp. Looks like it was a good paper!
I always mentally substituted FHE with “the ability to encrypt a function such that no attacker can reverse engineer how that function was implemented,” i.e. “input go in, output go brr.” Crucially, in FHE this is true even if you yourself are the one executing the program and can observe everything the program is doing.
Or... in whatever I thought FHE was.
- I encrypt data Encrypt(key, data) = ciphertext1
- you operate on encrypted data f(ciphertext1) = ciphertext2
- I decrypt the result to obtain Decrypt(key, ciphertext2) = f(data)
for iO it's more like: I give you the algorithm to encrypt your data: some_algorithm(data) = Encrypt(key, data)
but you can't figure out what "key" is, even though you have the code and it's not some remote service
Have I been using that term incorrectly? It’s possible. If so, what’s the canonical acronym for “encrypting a function”?
The term you are looking for is "obfuscation". Either black-box obfuscation (which was shown to be impossible) or the indistinguishability obfuscation, which is what the article talks about.
Obfuscation roughly means "encrypting a function." But here be dragons: since the adversary gets non-black-box access to the implementation of the function (a circuit), and can also learn as many (input, output = f(input)) pairs as they want, it becomes impossible to say that the adversary cannot learn anything else about f in the general case (intuitively, consider a higher-order function f: you could learn a lot about f by computing f(f)).
However, that book does look daunting. I am curious if the book hints at more potential problems than the abstract indicates.
I wish I had endless free time. It would be so, so fun to dive into this. Because you’re right — I got the sense that there were more potential problems than was previously appreciated. It would be fascinating to know exactly what problems there are, and whether they’re fundamental problems or “dodgeable.”
- present false source to claimed binary build of same.
- allow for pervasive backdoors in binary blobs that resist scrutiny by security researchers
Video/music DRM wouldn't (couldn't?) change from what it is now: the plaintext bits have to be surfaced to the user at some level (so that it can be displayed/played), so they can simply be ripped at that point.
So candidate plaintexts that are plausible sources for the obfuscated blob appears to be a capability of this approach.
> But iO is stronger than it sounds. For example, suppose you have a program that carries out some task related to your bank account, but the program contains your unencrypted password, making you vulnerable to anyone who gets hold of the program. Then — as long as there is some program out there that could perform the same task while keeping your password hidden — an indistinguishability obfuscator will be strong enough to successfully mask the password. After all, if it didn’t, then if you put both programs through the obfuscator, you’d be able to tell which obfuscated version came from your original program.
Why does existence of another mask the secret? Even if you couldn't distinguish the programs, couldn't you just try both possible secrets?
- Knowing program A allows an attacker to recover your password.
- Program B does not contain any information about your password.
Eve knows that these programs exist and that they have these properties. Eve is now given two obfuscated programs O1 and O2. They were produced by applying iO to A and B, but Eve knows neither A, B nor how O1 and O2 map to O(A) and O(B).
If it were possible for Eve to somehow obtain your password from, say (without loss of generality), O1 in any way, then Eve could deduce that O1 must be O(A). It could not be O(B) because neither O nor B contain information about your password.
Since we assert that indistinguishable obfuscation makes it impossible to draw this kind of conclusion, it must be impossible to obtain your password from O(A) if B exists.
Why does any of those programs contain the password anyway if it is not needed for achieving the goal?
If it is not needed, flow analysis, tree shaking and const evaluation could get rid of it.
If it is needed, how would the program not containing it achieve the goal?
As someone explained elsethread:
> iO gives you a circuit that is as hard to reverse engineer as the hardest circuit of a given size that computes the same function, but it doesn't give you a guarantee on how hard that actually is
https://news.ycombinator.com/item?id=25048220
To answer your thoughts though:
> If it is not needed, flow analysis, tree shaking and const evaluation coulg get rid of it.
Those are methods you could try to apply, but there is no reason why this would be sufficient in the general case.
> Why does any of those programs contain the password anyway if it is not needed for achieving the goal?
Maybe the problem your program is trying to solve is significantly easier given the knowledge of a secret. As long as you know that it's possible (but potentially harder) to solve the same problem without the secret, with iO you can distribute your obfuscated binary and nobody can recover the secret.
For example (if I understand correctly), if your secret program contained an oracle to reverse SHA256 hashes[0], then applying iO to it you could be sure that nobody can recover this secret oracle, because applying iO to a different program that uses brute-force search should yield an indistinguishable obfuscated program. I doubt that's how it actually works (because oracle and brute force are probably not the same "circuit hardness"), but I hope you see the point.
[0]before someone complains about lack of bijectivity, read this as "find the smallest integer/bitstring that has the same hash"
That's harder than it sounds. You can construct simple, iterative programs like `while(f(i++)){} return password;` whose behavior depends on hard problems like the Riemann Hypothesis (or easier problems which automated theorem provers still struggle with). Tree-shaking will be unfruitful, but if you can otherwise prove that an equivalent program exists that doesn't leak the password then iO gives an implementation.
One interesting additional property is that you don't need to come up with the program which doesn't leak a password; you just need to prove that one exists, which potentially might be substantially easier.
>For decades, computer scientists wondered if there is any secure, all-encompassing way to obfuscate computer programs, allowing people to use them without figuring out their internal secrets.
Obfuscate executable code? Somehow I don't think the original paper is talking about that.
<skims through the beginning of the paper>
They are?
But... how do you execute it then?
To elaborate:
Sure, your computer has to know all the numbers and instructions it executes. But that doesn't require your computer or you to understand what those numbers or instructions mean.
The meaning can be guarded by encryption. For example, if you are given a ROT13 encrypted text, you could uppercase all the letters without understanding the message. You perform an operation on the ciphertext without being able to decipher it, and the result (once decrypted) is exactly the same as if the operation had been applied to the plaintext. This is what fully homomorphic encryption (FHE) is about.
Going further, you can also have the effect of the instructions themselves be "hidden" by encryption. As a very simple example, imagine a programming language where all you can do is multiply numbers with constants (and there are different "instructions" for multiplying with different numbers). Your unencrypted program might be "multiply by 3, then multiply by 5, then multiply by 2". In encrypted form, this might become "multiply by 21, then multiply by 35, then multiply by 14" - that is, every factor is itself multiplied by seven, leading to different instructions. Someone running this encrypted program on (possibly homomorphically encrypted) data will not be able to figure out your original program (unless they know the "key" - that every factor was multiplied by seven). But when you get back the result, all you need to do is divide it by 7x7x7 to get back the output of the original program. And all the "difficult" computations (the actual instructions) have been performed on somebody else's machine without them knowing your original program (or your plaintext data, if the entire thing is also fully homomorphic).
I hope this example somewhat illustrates the concept (even though it is of course flawed and entirely trivial). Just imagine significantly more and better math instead of the simple operations (e.g. multiplication as only instruction, "decryption" by division etc.) used above. And of course, you can't just slap FHE on top independently, it needs to be built into the system. But the idea is the same.
For normal utility programs, I don't know. I mean, the data has to be unencrypted at some point for a human to make sense of it. What use is a fully obfuscated email client if you can't read your mail with it?
Why not?
Technically its talking about polynomial sized circuits, but that is roughly the same thing.
To quote the paper, the property they are looking for:
"(T, γ)-Indistinguishability: For every two ensembles {C_0,λ} {C_1,λ} of polynomial-sized circuits that have the same size, input length, and output length, and are functionally equivalent, that is, ∀λ, C_0,λ(x) = C_1,λ(x) for every input x, the following distributions are (T, γ)- indistinguishable: {iO(1^λ, C_0,λ)} {iO(1^λ, C_1,λ)}"
You still end up with executable code - i think the key thing is you get it to a form where you can't tell the difference between your function (after obfuscation) and any other function that gives the same output for same input (after obfuscation). So you could still try giving it every possible input, to figure out what it does, but if it takes at least a couple 64 bit integers you're going to be spending the rest of your life doing that.
Because you can execute it!
I wonder if this will be the Achilles heel. If there were a way to perform a task without needing a secret, you would not be using homomorphic encryption. You could just do regular computation since there is no secret. However, if the only way to perform the computation is with the secret, then Indistinguishability Obsfuscation won't help you. To me it seems that iO is useful only for computations that didn't need homomorphic encryption in the first place, because they already had a way to do the computation without the secret.
• https://www.youtube.com/watch?v=v2RR_c5hn1E
A cryptographic master tool called indistinguishability obfuscation has for years seemed too good to be true. Three researchers have figured out that it can work.
Reduced to 80 characters it is:
12345678901234567890123456789012345678901234567890123456789012345678901234567890
Three researchers have figured out how indistinguishability obfuscation can work
Sometimes the mods change them.
If you're going to spend 9 paragraphs talking about the controversy of whether such a thing is possible or not, dedicate at least 1 sentence at the start to explain it. Otherwise it's just confusing because as a reader, I have no idea why I should care or what's even worth caring about here.
Recommendation to anyone who hasn't read the article yet: start with the part called "The Crown Jewel".
I guess once I figure out what bootstrapping IO for C means, maybe I'll have a chance of understanding the paper. But I don't even know what bootstrapping means in this context.
I have no idea what:
"Indistinguishability obfuscation" is (it seems like some kind of mathematical inverse to Monty Hall but I doubt that's a clean take)
"polynomial size circuits" are (are they just talking about the number of variables in an equation? What does "size" and "circuits" mean here?)
"constant-degree graded encoding schemes" are (blu... bluh... uh...)
or what any of the above mean "in the plain model" (or what even is a "plain model").
That's the first 1/3rd of the first sentence of the abstract.
I don't have a problem with that, clearly it's an extremely specialised field so I don't mind being ignorant here, but the OP article doesn't really seem to help at all with the understanding.
The OP article has a nice picture with hidden lock boxes further down the page but this just feels like the whole quantum entanglement mystery all over again, where the analogy is more confusing than the observed phenomena.
I'm looking at a bunch of replies here like "isn't this just simply [x] with [slight y difference]" and making huge calls on the impact to society and I'm here wondering if I'm the only dumb person who doesn't get it.
I'll just add this is extremely interesting but it feels like this is going to take a few years for me to absorb what it means, unless I focus all my energy on it, which I'm not convinced I should just yet.
If writers write good introduction paragraph, it gauges my interest and I am more likely to read.
Otherwise, I don't read out of spite or protest.
That it's important for you to write as an author, but it doesn't serve the reader well.
From https://www.quantamagazine.org/authors/erica-klarreich/:
> About the author
> Erica Klarreich has been writing about mathematics and science for more than 15 years. She has a doctorate in mathematics from Stony Brook University and is a graduate of the Science Communication Program at the University of California, Santa Cruz.
As someone who works in cryptography, this isn't "The Crown Jewel" of Cryptography.
Cryptography to me is about helping queer people live their best life even in countries where they're hated.
Cryptography to me is about providing assurance that the software you're running was produced by the people you thought produced it, and that the built binary is reproducible from the source code, which technical people can also inspect to assert the absence of backdoors.
Obfuscation and copy-protection are non-goals for me. Fully homomorphic encryption has uses in machine learning and cloud services, but I find them at odds with the goals I care about.
The point is that we don't know what's going to come out ahead of time.
How can you expect people being targeted by hostile nation states to trust obfuscated closed-source software to protect them from said nation states?
Binary obfuscation techniques to evade signature detection are a dime a dozen. The only time this intersects with homomorphic encryption is when you're dealing with DRM and other privacy-adverse technologies.
Fully encrypted programs that can perform and can run on an untrusted platform are not. I think you may have a little more reading to do.
However, that doesn't mean that iO isn't useful for tasks that you might care about. For example,
* deniable encryption (https://eprint.iacr.org/2013/454.pdf),
* better constructions of post-quantum NIZKs (which can help with ensuring that a remote server is behaving honestly),
* proving results about the hardness of finding Nash equilibria (https://ieeexplore.ieee.org/abstract/document/7354468)
Real-world cryptography and security engineering intersect a lot.