Package zeroecho.core.alg.slhdsa


package zeroecho.core.alg.slhdsa
SLH-DSA (FIPS 205) signature algorithm binding.

This package provides a ZeroEcho binding for SLH-DSA, the NIST-standardized profile of the stateless hash-based signature scheme SPHINCS+. While SLH-DSA is derived from SPHINCS+, it is exposed here as a distinct algorithm identity with a restricted, standards-compliant parameter space.

Algorithm identity

  • JCA algorithm name: "SLH-DSA"
  • ZeroEcho algorithm id: "SLHDSA"
  • Provider: Bouncy Castle core provider ("BC")

Supported parameter space

The supported parameters correspond exactly to the SLH-DSA profiles defined by FIPS 205:

  • Hash families: SHA2 and SHAKE
  • Security levels: 128, 192, 256 bits (NIST levels L1, L3, L5)
  • Variants: FAST (larger, faster signatures) and SMALL (smaller, slower signatures)
  • Optional pre-hash variants as defined by the standard and exposed by the provider

Non-standard SPHINCS+ variants (e.g. Haraka, simple/robust modes) are intentionally excluded from this package.

Key management

Streaming signature model

Signatures are processed through the ZeroEcho streaming signature infrastructure:

  • In KeyUsage.SIGN mode, the signature is appended as a fixed-length trailer to the output stream.
  • In KeyUsage.VERIFY mode, the wrapped stream emits only the message body; verification is performed at end-of-stream against a caller-supplied expected signature.

The canonical signature length is derived from the public key parameters by SlhDsaSignatureContext and matches the standard SLH-DSA signature sizes defined by FIPS 205.

Security considerations

  • No sensitive material (private keys, signatures, message contents) is logged or exposed by this package.
  • All byte arrays returned to callers are defensive copies.
  • Verification failures are surfaced exclusively via the configured verification strategy.

Relationship to SPHINCS+

The slhdsa package represents the standardized SLH-DSA profile only. A separate sphincsplus package may expose the full SPHINCS+ design space and experimental variants. No API-level equivalence between the two packages is assumed.

Since:
1.0