package hacl-star

  1. Overview
  2. Docs
OCaml API for EverCrypt/HACL*

Install

Dune Dependency

Authors

Maintainers

Sources

hacl-star.0.6.2.tar.gz
md5=1d8449a395cf9f0ade232da306b2316f
sha512=0aa0afc951b30164aca98100ad528f13129566957a3db26bac3c1975c264c4dece01c2b918ad2f9d1b8b563b13044c85ecfdcbced13aee915e4b9d61bff25bf5

doc/hacl-star/Hacl_star/Hacl/index.html

Module Hacl_star.HaclSource

This module provides direct access to all HACL* implementations

bytes is ultimately an alias for Stdlib.Bytes.t, the type of buffers currently used throughout the library

AEAD

Chacha20-Poly1305

Different implementations of Chacha20-Poly1305. A multiplexing interface is also available.

Portable C implementation of Chacha20-Poly1305 that runs on any 32-bit platform

128-bit vectorized C implementation of Chacha20-Poly1305 that runs on platforms with 128-bit vector support

256-bit vectorized C implementation of Chacha20-Poly1305 that runs on platforms with 256-bit vector support

ECDH, EdDSA, and ECDSA

Curve25519

Different implementations of ECDH using Curve25519. A multiplexing interface is also available.

Portable C implementation that is optimized for use on 64-bit platforms that support 128-bit arithmetic, will still compile and execute on 32-bit platforms

Hybrid C/assembly implementation: the field arithmetic functions are in Intel assembly (generated by Vale) and rely on the Intel ADX and BMI2 instruction sets; the elliptic curve functions and the main API are in portable C

Ed25519

EdDSA using Curve25519

Portable implementation

P-256

Sourcemodule P256 : sig ... end

ECDSA and ECDH functions using P-256

Hashing

SHA-2

Portable C implementations of SHA-2. Multiplexing interfaces for SHA-224 and SHA-256 are also available.

Direct hashing with SHA-224

Direct hashing with SHA-256

Direct hashing with SHA-384

Direct hashing with SHA-512

SHA-3

Portable C implementations of SHA-3

Direct hashing with SHA3-224

Direct hashing with SHA3-256

Direct hashing with SHA3-384

Direct hashing with SHA3-512

Sourcemodule Keccak : sig ... end

SHAKE-128, SHAKE-256, and the general Keccak function

BLAKE2

The BLAKE2 hash function has 2 variants:

  • BLAKE2b, optimised for 64-bit architectures
  • BLAKE2s, optimised for 8- to 32-bit architectures

Portable BLAKE2b implementation

Vectorized BLAKE2b implementation, requiring 256-bit vector support

Portable BLAKE2s implementation

Vectorized BLAKE2s implementation, requiring 128-bit vector support

Legacy (deprecated)

Legacy algorithms, which are not suitable for cryptographic applications.

Direct hashing with MD5

Direct hashing with SHA-1

MACs

Message authentication codes

Multiplexing interfaces for these algorithms are also available.

HMAC

Portable C implementation of HMAC-SHA-256

Portable C implementation of HMAC-SHA-384

Portable C implementation of HMAC-SHA-512

Portable C implementation of HMAC-BLAKE2b

Portable C implementation of HMAC-BLAKE2s

Poly1305

Portable C implementation of Poly1305

Vectorized C implementation of Poly1305 that runs on platforms with 128-bit vector support

Vectorized C implementation of Poly1305 that runs on platforms with 256-bit vector support

NaCl

Sourcemodule NaCl : sig ... end

Box (public-key authenticated encryption) and Secretbox (secret-key authenticated encryption)

Key derivation

HKDF

HMAC-based key derivation function

Portable implementations of HKDF. Agile and multiplexing interfaces are also available.

Portable C implementation of HKDF using SHA2-256

Portable C implementation of HKDF using SHA2-512

Portable C implementation of HKDF using BLAKE2b

Portable C implementation of HKDF using BLAKE2s

Randomness (not verified)

Sourcemodule RandomBuffer : sig ... end

A randomness function implemented with platform-dependent code for Unix and Windows

OCaml

Innovation. Community. Security.