Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Homomorphic Encryption #11

Open
puff opened this issue May 26, 2023 · 0 comments
Open

Homomorphic Encryption #11

puff opened this issue May 26, 2023 · 0 comments
Labels
enhancement New feature or request needs more info Further information is requested

Comments

@puff
Copy link
Owner

puff commented May 26, 2023

Currently, this project does not support decrypting branches encrypted with homomorphic encryption.

Here's a basic representation of how HM works in eaz:

// pretend this is virtualized code
var input = int.Parse(Console.ReadLine());
if (Encrypt(input) == encryptedConstant)
{
  // Homomorphic Encryption Start VM OpCode
  var oldReader = VM.VMInstructionsReader;
  VM.VMInstructionsReader = new VMInstructionsReader(decryptionKey: input);

  // next instructions will be decrypted with the new key
  Console.WriteLine("homomorphic encryption woah");
  
  // Homomorphic Encryption End VM OpCode
  VM.VMInstructionsReader = oldReader;
}
// next instructions will be decrypted with the original decryption key
Console.WriteLine("this uses the original instructions reader");

Untested but looks like it can be nested too.

@puff puff added enhancement New feature or request needs more info Further information is requested labels May 26, 2023
@puff puff changed the title Support homomorphic encryption Homomorphic Encryption Jan 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request needs more info Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant