Org.BouncyCastle.Crypto.Parameters.MLDsaPrivateKeyParameters
ML-DSA private key (FIPS 204). The expanded key holds (ρ, K, tr, s₁, s₂, t₀) derived from
a 32-byte seed; the corresponding t₁ half of the public key is cached for fast public-key
recovery. A key built from a seed retains the seed so it can be re-encoded in the seed format.
Storage format selector for serialised private keys. Per RFC 9881 §8.1 the seed form is
preferred for storage efficiency.
Default Format applied when a key is constructed from a seed.
The serialisation format this key was last asked to prefer.
Decode a private key from its expanded byte representation. The expected length is the
parameter set's PrivateKeyLength; the returned key has EncodingOnly
as its preferred format because the seed is not recoverable from the encoding.
Expand a 32-byte seed into a private key, defaulting to DefaultFormat
( SeedOnly).
public static MLDsaPrivateKeyParameters FromSeed(MLDsaParameters parameters, byte[] seed, Format preferredFormat)
Expand a 32-byte seed into a private key with the supplied preferredFormat.
Return a fresh copy of the expanded ρ || K || tr || s₁ || s₂ || t₀ encoding.
Return the public key derived during key expansion.
Return a fresh copy of the public key encoding (ρ || t₁).
Return a fresh copy of the 32-byte seed if one was retained at construction; null for
keys imported via FromEncoding.
Return a key equivalent to this one but with PreferredFormat changed to
preferredFormat. Returns the receiver when the format is unchanged.