Documentation

Complexity.Crypto.Computational.Pseudoentropy.EntropyGrid

An expanding grid of entropy guesses #

A dyadic grid guesses the observation entropy and the conditional label entropy. Every guess assigns enough total digest bits to expand, including incorrect guesses. Rounding the true entropies down gives a candidate satisfying all three extraction budgets whenever the prediction gap covers four grid steps. The entropy-dependent choice appears only in the existence proof.

The grid and its output lengths use ordinary unary arithmetic. Their polynomial-time certificates apply to arbitrary captured inputs, so later reductions can enumerate the family.

Main definitions #

Main results #

References #

Adapted from the cslib crypto branch at 5ff69ca93402e7c947208dc56396d6d86203ccd8, using typed polynomial-time certificates.

Enumerate an observation guess up to the seed entropy and a label guess below one.

Instances For
    @[simp]
    theorem Cslib.Crypto.Pseudoentropy.EntropyGrid.size_pos (sourceBits bound : ℕ) :
    0 < size sourceBits bound

    The grid is nonempty, including when the source has no seed bits.

    One unit is the two-slack reserve in the extraction schedule.

    Instances For

      Digest length for the observation source, with a zero floor.

      Instances For
        def Cslib.Crypto.Pseudoentropy.EntropyGrid.labelBits (n sourceBits bound index : ℕ) :

        Digest length for the hidden labels, using part of the pseudoentropy surplus.

        Instances For

          Digest length for the saved seed after revealing both components.

          Instances For

            The soft-mask density numerator, four grid steps above the label guess.

            Instances For

              The grid has polynomially many entries.

              The observation digest length is uniformly efficient in the candidate index.

              The label digest length is uniformly efficient in the candidate index.

              The retained-seed digest length is uniformly efficient in the candidate index.

              The requested density is uniformly efficient in the candidate index.

              No candidate asks for zero soft-mask mass.

              theorem Cslib.Crypto.Pseudoentropy.EntropyGrid.scale_pos (n sourceBits bound : ℕ) :
              0 < scale n sourceBits bound

              The integer unit is positive even at security parameter zero.

              theorem Cslib.Crypto.Pseudoentropy.EntropyGrid.count_eq (n sourceBits bound : ℕ) :
              ExtractionSchedule.count n sourceBits (Probability.dyadicSize bound - 1) = 2 * scale n sourceBits bound * Probability.dyadicSize bound

              The repetition count is exactly two units per grid step.

              theorem Cslib.Crypto.Pseudoentropy.EntropyGrid.expands (n sourceBits bound index : ℕ) :
              ExtractionSchedule.count n sourceBits (Probability.dyadicSize bound - 1) * sourceBits < observationBits n sourceBits bound index + labelBits n sourceBits bound index + remainingBits n sourceBits bound index

              All candidates expand, whether or not their entropy guesses are accurate.

              theorem Cslib.Crypto.Pseudoentropy.EntropyGrid.label_budget (n sourceBits bound index : ℕ) :
              ↑(labelBits n sourceBits bound index) + ↑(scale n sourceBits bound) = ↑(ExtractionSchedule.count n sourceBits (Probability.dyadicSize bound - 1)) * (↑(numerator bound index) / ↑(Probability.dyadicSize bound))

              The label budget holds exactly for every candidate, independent of entropy assumptions.

              structure Cslib.Crypto.Pseudoentropy.EntropyGrid.Valid (n sourceBits bound index : ℕ) (observationEntropy labelEntropy gap : ℝ) :

              The entropy assumptions required of a useful entry. Indexing and expansion are separate from security: inaccurate entries are still total expanding programs.

              Instances For
                theorem Cslib.Crypto.Pseudoentropy.EntropyGrid.exists_valid (n sourceBits bound : ℕ) {observationEntropy labelEntropy gap : ℝ} (hobservation : 0 ≤ observationEntropy) (hlabel : 0 ≤ labelEntropy) (htotal : observationEntropy + labelEntropy ≤ ↑sourceBits) (hgap : 4 / ↑(Probability.dyadicSize bound) ≤ gap) (hone : labelEntropy + gap ≤ 1) :
                ∃ (index : ℕ), Valid n sourceBits bound index observationEntropy labelEntropy gap

                Rounding both true entropies down supplies a valid candidate. Four grid steps of pseudoentropy suffice; no algorithm for computing either entropy is assumed.