Class SDitHParameters

java.lang.Object
org.bouncycastle.pqc.crypto.sdith.SDitHParameters

public class SDitHParameters extends Object
SDitH parameter set descriptor.

SDitH (Syndrome-Decoding-in-the-Head) has 24 NIST-submitted variants formed from the cross of:

  • MPC structure: Hypercube or Threshold,
  • NIST category: 1, 3, or 5,
  • Field: GF(256) or P251.
The current Bouncy Castle port wires up the Hypercube / Category 1 / GF(256) variant matching the shipped reference KAT vectors. Additional variants can be added by populating new public static final constants here and adding the corresponding precomputed tables to SDitHPrecomputed.

The numeric fields follow the reference param.h convention:

  • m: code length,
  • k: code dimension,
  • w: Hamming weight bound on the SD solution,
  • d: splitting factor (number of twists),
  • t: number of MPC evaluation points per iteration,
  • tau: number of parallel MPC repetitions,
  • dimD: hypercube dimension (2^D leaf parties),
  • seedSize, rhoSize, saltSize, commitSize, hashSize: in bytes,
  • fpointSize: extension-field byte width (3 or 4),
  • hashBits: SHA3 variant used for commitments and Fiat-Shamir,
  • xofBits: SHAKE variant used as XOF.
  • Field Details

    • VARIANT_HYPERCUBE

      public static final int VARIANT_HYPERCUBE
      See Also:
    • VARIANT_THRESHOLD

      public static final int VARIANT_THRESHOLD
      See Also:
    • FIELD_GF256

      public static final int FIELD_GF256
      See Also:
    • FIELD_P251

      public static final int FIELD_P251
      See Also:
    • sdith_hypercube_cat1_gf256

      public static final SDitHParameters sdith_hypercube_cat1_gf256
    • sdith_hypercube_cat3_gf256

      public static final SDitHParameters sdith_hypercube_cat3_gf256
    • sdith_hypercube_cat5_gf256

      public static final SDitHParameters sdith_hypercube_cat5_gf256
    • sdith_hypercube_cat1_p251

      public static final SDitHParameters sdith_hypercube_cat1_p251
    • sdith_hypercube_cat3_p251

      public static final SDitHParameters sdith_hypercube_cat3_p251
    • sdith_hypercube_cat5_p251

      public static final SDitHParameters sdith_hypercube_cat5_p251
    • sdith_threshold_cat1_gf256

      public static final SDitHParameters sdith_threshold_cat1_gf256
    • sdith_threshold_cat3_gf256

      public static final SDitHParameters sdith_threshold_cat3_gf256
    • sdith_threshold_cat5_gf256

      public static final SDitHParameters sdith_threshold_cat5_gf256
    • sdith_threshold_cat1_p251

      public static final SDitHParameters sdith_threshold_cat1_p251
    • sdith_threshold_cat3_p251

      public static final SDitHParameters sdith_threshold_cat3_p251
    • sdith_threshold_cat5_p251

      public static final SDitHParameters sdith_threshold_cat5_p251
  • Method Details

    • getNbRevealed

      public int getNbRevealed()
      Threshold variant: number of revealed parties per execution. Zero for hypercube variants.
    • getTreeMaxOpenLeaves

      public int getTreeMaxOpenLeaves()
      Threshold variant: upper bound on Merkle authentication-path nodes per execution. Zero for hypercube variants.
    • getNbParties

      public int getNbParties()
      Threshold variant: number of MPC parties. For GF(256) this is 256 (1 << dimD); for GF(p251) it is 251 (= the prime field size). The Merkle tree always has 1 << dimD max capacity but only getNbParties() leaves are populated for the p251 variants.
    • getName

      public String getName()
    • getVariant

      public int getVariant()
    • getField

      public int getField()
    • getCategory

      public int getCategory()
    • getM

      public int getM()
    • getK

      public int getK()
    • getW

      public int getW()
    • getD

      public int getD()
    • getT

      public int getT()
    • getTau

      public int getTau()
    • getDimD

      public int getDimD()
    • getSeedSize

      public int getSeedSize()
    • getRhoSize

      public int getRhoSize()
    • getSaltSize

      public int getSaltSize()
    • getCommitSize

      public int getCommitSize()
    • getHashSize

      public int getHashSize()
    • getFpointSize

      public int getFpointSize()
    • getHashBits

      public int getHashBits()
    • getXofBits

      public int getXofBits()
    • getWd

      public int getWd()
    • getYSize

      public int getYSize()
    • getHaNSlice

      public int getHaNSlice()
    • getMd

      public int getMd()
    • getFpointMask

      public int getFpointMask()