Thanks to visit codestin.com
Credit goes to pkg.go.dev

mlkemtest

package standard library
go1.26.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 10, 2026 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Overview

Package mlkemtest provides testing functions for the ML-KEM algorithm.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Encapsulate768

func Encapsulate768(ek *mlkem.EncapsulationKey768, random []byte) (sharedKey, ciphertext []byte, err error)

Encapsulate768 implements derandomized ML-KEM-768 encapsulation (ML-KEM.Encaps_internal from FIPS 203) using the provided encapsulation key ek and 32 bytes of randomness.

It must only be used for known-answer tests.

func Encapsulate1024

func Encapsulate1024(ek *mlkem.EncapsulationKey1024, random []byte) (sharedKey, ciphertext []byte, err error)

Encapsulate1024 implements derandomized ML-KEM-1024 encapsulation (ML-KEM.Encaps_internal from FIPS 203) using the provided encapsulation key ek and 32 bytes of randomness.

It must only be used for known-answer tests.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL