Documentation

Complexity.Crypto.Computational.Homomorphic.Basic

Homomorphic encryption on bit strings #

This module records the algorithms and perfect correctness of bit-encryption schemes with a specified family of permitted Boolean circuits, following [Gentry2009, Definitions 1 and 5]. Algorithms are terminating probabilistic programs. Uniform efficiency and semantic security are separate obligations; neither follows from this interface or its correctness property.

Homomorphic correctness is required on pointwise supported fresh encryptions. Inputs may share randomness or repeat a ciphertext, as happens when the same encrypted secret key is used twice in an augmented decryption circuit. No independence hypothesis is imposed on these inputs.

Scheme.FixedWidth describes a padded representation whose ciphertext width depends only on the security parameter. It asserts a representation bound, not that the width is polynomial.

Main definitions #

Main results #

References #

Algorithms of a bit-encryption scheme, with a unary security parameter. evaluate receives an actual Boolean circuit and an ordered list of ciphertexts. Correctness, uniform efficiency, and security are separate properties.

Instances For

    Each ciphertext is a supported fresh encryption of the corresponding plaintext bit. The relation implies equal list lengths, and permits repeated ciphertexts.

    Instances For

      Perfect correctness of encryption and evaluation of permitted circuits on fresh inputs. The evaluator need not accept its own outputs as inputs: bootstrapping will derive that closure.

      Instances For
        structure Cslib.Crypto.Homomorphic.Scheme.FixedWidth (E : Scheme) (secretWidth ciphertextWidth : ℕ → ℕ) :

        A fixed-width representation for supported keys and ciphertexts. Both fresh encryption and evaluation outputs have the same width, independent of circuit size and evaluation depth. Polynomial bounds on these width functions are a separate efficiency obligation.

        Instances For

          Encrypt every bit of a public word using a fresh call to the base encryption algorithm.

          Instances For
            theorem Cslib.Crypto.Homomorphic.Scheme.mem_support_encryptBits_iff (E : Scheme) (n : ℕ) (pk bits : List Bool) (inputs : List (List Bool)) :
            inputs ∈ (E.encryptBits n pk bits).eval.support ↔ E.FreshInputs n pk bits inputs

            Bitwise encryption has exactly the pointwise fresh-encryption support.