diff options
| author | tb <> | 2026-01-16 18:29:58 +0000 |
|---|---|---|
| committer | tb <> | 2026-01-16 18:29:58 +0000 |
| commit | dcbd53bcbd78c031d6d012192ac183de96a3082f (patch) | |
| tree | a347ea2e5f3a543374b80f2a6d16d47918fd46d7 /src | |
| parent | 591a62834f9696acafe181bbaa784aae617b260e (diff) | |
| download | openbsd-dcbd53bcbd78c031d6d012192ac183de96a3082f.tar.gz openbsd-dcbd53bcbd78c031d6d012192ac183de96a3082f.tar.bz2 openbsd-dcbd53bcbd78c031d6d012192ac183de96a3082f.zip | |
mlkem_internal.h: some very basic copy editing
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libcrypto/mlkem/mlkem_internal.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/lib/libcrypto/mlkem/mlkem_internal.h b/src/lib/libcrypto/mlkem/mlkem_internal.h index 2b3157256e..30141a4faf 100644 --- a/src/lib/libcrypto/mlkem/mlkem_internal.h +++ b/src/lib/libcrypto/mlkem/mlkem_internal.h | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: mlkem_internal.h,v 1.10 2025/09/05 23:30:12 beck Exp $ */ | 1 | /* $OpenBSD: mlkem_internal.h,v 1.11 2026/01/16 18:29:58 tb Exp $ */ |
| 2 | /* | 2 | /* |
| 3 | * Copyright (c) 2023, Google Inc. | 3 | * Copyright (c) 2023, Google Inc. |
| 4 | * Copyright (c) 2025, Bob Beck <beck@obtuse.com> | 4 | * Copyright (c) 2025, Bob Beck <beck@obtuse.com> |
| @@ -186,9 +186,9 @@ int mlkem_generate_key(uint8_t *out_encoded_public_key, | |||
| 186 | uint8_t *optional_out_seed, MLKEM_private_key *out_private_key); | 186 | uint8_t *optional_out_seed, MLKEM_private_key *out_private_key); |
| 187 | 187 | ||
| 188 | /* | 188 | /* |
| 189 | * mlkem_private_key_from_seed modifies |out_private_key| to generate a key of | 189 | * mlkem_private_key_from_seed modifies |out_private_key| to contain a key of |
| 190 | * the rank of |*out_private_key| from a seed that was generated by | 190 | * the rank of |*out_private_key| from a seed that was generated by |
| 191 | * |mlkem_generate_key|. It fails and returns 0 if |seed_len| is incorrect, or | 191 | * |MLKEM_generate_key|. It fails and returns 0 if |seed_len| is incorrect, or |
| 192 | * if |*out_private_key| has not been initialized. otherwise it writes to | 192 | * if |*out_private_key| has not been initialized. otherwise it writes to |
| 193 | * |*out_private_key| and returns 1. | 193 | * |*out_private_key| and returns 1. |
| 194 | */ | 194 | */ |
| @@ -266,8 +266,8 @@ int mlkem_parse_private_key(const uint8_t *input, size_t input_len, | |||
| 266 | 266 | ||
| 267 | /* | 267 | /* |
| 268 | * mlkem_generate_key_external_entropy is a deterministic function to create a | 268 | * mlkem_generate_key_external_entropy is a deterministic function to create a |
| 269 | * pair of ML-KEM 768 keys, using the supplied entropy. The entropy needs to be | 269 | * pair of ML-KEM keys, using the supplied entropy. The entropy needs to be |
| 270 | * uniformly random generated. This function is should only be used for tests, | 270 | * uniformly random generated. This function should only be used for tests, |
| 271 | * regular callers should use the non-deterministic |MLKEM_generate_key| | 271 | * regular callers should use the non-deterministic |MLKEM_generate_key| |
| 272 | * directly. | 272 | * directly. |
| 273 | */ | 273 | */ |
| @@ -285,7 +285,7 @@ int mlkem_marshal_private_key(const MLKEM_private_key *private_key, | |||
| 285 | uint8_t **out_private_key, size_t *out_private_key_len); | 285 | uint8_t **out_private_key, size_t *out_private_key_len); |
| 286 | 286 | ||
| 287 | /* | 287 | /* |
| 288 | * mlkem_encap_external_entropy behaves like |mlkem_encap|, but uses | 288 | * mlkem_encap_external_entropy behaves like |MLKEM_encap|, but uses |
| 289 | * |MLKEM_ENCAP_ENTROPY| bytes of |entropy| for randomization. The decapsulating | 289 | * |MLKEM_ENCAP_ENTROPY| bytes of |entropy| for randomization. The decapsulating |
| 290 | * side will be able to recover |entropy| in full. This function should only be | 290 | * side will be able to recover |entropy| in full. This function should only be |
| 291 | * used for tests, regular callers should use the non-deterministic | 291 | * used for tests, regular callers should use the non-deterministic |
