package mldsa

Import Path
	crypto/internal/fips140/mldsa (on go.dev)

Dependency Relation
	imports 12 packages, and imported by 0 packages


Package-Level Type Names (total 2)
/* sort by: | */
(*PrivateKey) Bytes() []byte (*PrivateKey) Equal(x *PrivateKey) bool (*PrivateKey) PublicKey() *PublicKey func GenerateKey44() *PrivateKey func GenerateKey65() *PrivateKey func GenerateKey87() *PrivateKey func NewPrivateKey44(seed []byte) (*PrivateKey, error) func NewPrivateKey65(seed []byte) (*PrivateKey, error) func NewPrivateKey87(seed []byte) (*PrivateKey, error) func TestingOnlyNewPrivateKeyFromSemiExpanded(sk []byte) (*PrivateKey, error) func Sign(priv *PrivateKey, msg []byte, context string) ([]byte, error) func SignDeterministic(priv *PrivateKey, msg []byte, context string) ([]byte, error) func SignExternalMu(priv *PrivateKey, μ []byte) ([]byte, error) func SignExternalMuDeterministic(priv *PrivateKey, μ []byte) ([]byte, error) func TestingOnlyPrivateKeySemiExpandedBytes(priv *PrivateKey) []byte func TestingOnlySignExternalMuWithRandom(priv *PrivateKey, μ []byte, random []byte) ([]byte, error) func TestingOnlySignWithRandom(priv *PrivateKey, msg []byte, context string, random []byte) ([]byte, error) func (*PrivateKey).Equal(x *PrivateKey) bool
(*PublicKey) Bytes() []byte (*PublicKey) Equal(x *PublicKey) bool (*PublicKey) Parameters() string func NewPublicKey44(pk []byte) (*PublicKey, error) func NewPublicKey65(pk []byte) (*PublicKey, error) func NewPublicKey87(pk []byte) (*PublicKey, error) func (*PrivateKey).PublicKey() *PublicKey func Verify(pub *PublicKey, msg, sig []byte, context string) error func VerifyExternalMu(pub *PublicKey, μ []byte, sig []byte) error func (*PublicKey).Equal(x *PublicKey) bool
Package-Level Functions (total 19)
func Sign(priv *PrivateKey, msg []byte, context string) ([]byte, error)
func SignDeterministic(priv *PrivateKey, msg []byte, context string) ([]byte, error)
func SignExternalMu(priv *PrivateKey, μ []byte) ([]byte, error)
TestingOnlyNewPrivateKeyFromSemiExpanded creates a PrivateKey from a semi-expanded private key encoding, for testing purposes. It rejects inconsistent keys. [PrivateKey.Bytes] must NOT be called on the resulting key, as it will produce a random value.
func TestingOnlySignWithRandom(priv *PrivateKey, msg []byte, context string, random []byte) ([]byte, error)
func Verify(pub *PublicKey, msg, sig []byte, context string) error
func VerifyExternalMu(pub *PublicKey, μ []byte, sig []byte) error
Package-Level Constants (total 9)
const PrivateKeySize = 32
const PublicKeySize44 = 1312
const PublicKeySize65 = 1952
const PublicKeySize87 = 2592
const R = 4294967296 // 2³²
const RR = 2365951 // R² mod q, aka R in the Montgomery domain
const SignatureSize44 = 2420
const SignatureSize65 = 3309
const SignatureSize87 = 4627