Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename mlkem-c-aarch64 to mlkem-native #364

Merged
merged 1 commit into from
Nov 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/actions/bench/action.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# SPDX-License-Identifier: Apache-2.0

name: Bench MLKEM-C-AArch64
name: Bench mlkem-native
description: Run benchmarking script

inputs:
Expand Down
26 changes: 12 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,36 +1,34 @@
[//]: # (SPDX-License-Identifier: CC-BY-4.0)

# mlkem-c-aarch64
# mlkem-native

**mlkem-c-aarch64** is a C99 implementation of [ML-KEM](https://doi.org/10.6028/NIST.FIPS.203.ipd) targeting
**mlkem-native** is a C99 implementation of [ML-KEM](https://doi.org/10.6028/NIST.FIPS.203.ipd) targeting
PC, mobile and server platforms. It is a fork of the ML-KEM [reference
implementation](https://github.com/pq-crystals/kyber/tree/main/ref) and remains very close to it, adding a simple
interface for native code (e.g. assembler) as well as implementations of that interface in C, AArch64, and x86_64.

If you need an ML-KEM implementation suitable for embedded systems, see
[**mlkem-c-embedded**](https://github.com/pq-code-package/mlkem-c-embedded/).

**Note on naming:** **mlkem-c-aarch64** is a misnomer reflecting the original focus on AArch64. The project is likely to be renamed to
reflect its broadened scope.

### Goals

**mlkem-c-aarch64** aims for _assurance_, _ease of use_, and _performance_. We only include implementations into
**mlkem-c-aarch64** which are manually auditable or for which we see a path towards formal verification. All assembly aims
**mlkem-native** aims for _assurance_, _ease of use_, and _performance_. We only include implementations into
**mlkem-native** which are manually auditable or for which we see a path towards formal verification. All assembly aims
to be readable and micro-optimization deferred to automated tooling such as
[SLOTHY](https://slothy-optimizer.github.io/slothy/). Ultimately, **mlkem-c-aarch64** strives for constant-time
[SLOTHY](https://slothy-optimizer.github.io/slothy/). Ultimately, **mlkem-native** strives for constant-time
implementations for which the C-code is verified to be free of undefined behaviour, and where all assembly is
functionally verified.

### Current state

**mlkem-c-aarch64** is work in progress. **WE DO NOT CURRENTLY RECOMMEND RELYING ON THIS LIBRARY IN A PRODUCTION
**mlkem-native** is work in progress. **WE DO NOT CURRENTLY RECOMMEND RELYING ON THIS LIBRARY IN A PRODUCTION
ENVIRONMENT OR TO PROTECT ANY SENSITIVE DATA.** Once we have the first stable version, this notice will be removed.

#### Performance

**mlkem-c-aarch64** has complete AArch64 and AVX2 backends of competitive performance (see
[benchmarks](https://pq-code-package.github.io/mlkem-c-aarch64/dev/bench/)).
**mlkem-native** has complete AArch64 and AVX2 backends of competitive performance (see
[benchmarks](https://pq-code-package.github.io/mlkem-native/dev/bench/)).

#### Verification

Expand All @@ -51,7 +49,7 @@ nix develop --experimental-features 'nix-command flakes'

### Native setup

To build **mlkem-c-aarch64**, you need `make` and a C99 compiler. To use the test scripts, you need Python3 with
To build **mlkem-native**, you need `make` and a C99 compiler. To use the test scripts, you need Python3 with
dependencies as specified in [requirements.txt](requirements.txt). We recommend using a virtual environment, e.g.:

```bash
Expand Down Expand Up @@ -88,10 +86,10 @@ will compile and run functionality tests. For detailed information on how to use

### Call for contributors

We are actively seeking contributors who can help us build **mlkem-c-aarch64**. If you are interested, please contact us,
We are actively seeking contributors who can help us build **mlkem-native**. If you are interested, please contact us,
or volunteer for any of the open issues.

### Call for potential consumers

If you are a potential consumer of **mlkem-c-aarch64**, please reach out: We're interested in hearing the way you want to
use **mlkem-c-aarch64**. If you have specific feature requests, please open an issue.
If you are a potential consumer of **mlkem-native**, please reach out: We're interested in hearing the way you want to
use **mlkem-native**. If you have specific feature requests, please open an issue.
2 changes: 1 addition & 1 deletion cbmc/proofs/Makefile-template-defines
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ LITANI ?= litani
#
# make PROJECT_NAME="FreeRTOS MQTT" report
#
PROJECT_NAME = "mlkem-c-aarch64"
PROJECT_NAME = "mlkem-native"
2 changes: 1 addition & 1 deletion cbmc/proofs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ CBMC proofs
# Overview

This directory contains [CBMC](https://github.com/diffblue/cbmc) proofs for the absence
of certain classes of undefined behaviour for parts of the C-code in MLKEM-C-AArch64.
of certain classes of undefined behaviour for parts of the C-code in mlkem-native.

Proofs are organized by functions, with the harnesses and proofs for each function
in a separate directory.
Expand Down
2 changes: 1 addition & 1 deletion fips202/native/x86_64/xkcp/KeccakP-1600-times4-SIMD256.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ and related or neighboring rights to the source code in this file.
*/

/*
* Changes for MLKEM-C-AArch64:
* Changes for mlkem-native:
* - copyFromState and copyToState operate on uninterleaved
* Keccak states in memory.
*/
Expand Down
2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SPDX-License-Identifier: Apache-2.0

{
description = "mlkem-c-aarch64";
description = "mlkem-native";

inputs = {
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
Expand Down
Loading