Skip to content

Commit

Permalink
Merge branch 'document-kyber-prococol-version'
Browse files Browse the repository at this point in the history
  • Loading branch information
faern committed Jul 11, 2024
2 parents f22a319 + a1c6311 commit 5bd43f9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions talpid-tunnel-config-client/examples/tuncfg-server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ impl EphemeralPeer for EphemeralPeerImpl {
classic_mceliece_rust::encapsulate_boxed(&public_key, &mut rng);
(ciphertext.as_array().to_vec(), *shared_secret.as_array())
}
// Kyber round3
"Kyber1024" => {
let public_key = kem_pubkey.key_data.as_slice();
let (ciphertext, shared_secret) =
Expand Down
2 changes: 1 addition & 1 deletion talpid-tunnel-config-client/proto/ephemeralpeer.proto
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ message EphemeralPeerRequestV1 {
// The v1 request supports exactly two algorithms.
// The algorithms can appear soletary or in mixed order:
// - "Classic-McEliece-460896f", but explicitly identified as "Classic-McEliece-460896f-round3"
// - "Kyber1024"
// - "Kyber1024", this is round3 of the Kyber KEM
message PostQuantumRequestV1 { repeated KemPubkeyV1 kem_pubkeys = 1; }

message KemPubkeyV1 {
Expand Down
3 changes: 3 additions & 0 deletions talpid-tunnel-config-client/src/kyber.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
//! This module implements the Kyber round3 KEM as specified in:
//! https://pq-crystals.org/kyber/data/kyber-specification-round3.pdf
use pqc_kyber::KYBER_CIPHERTEXTBYTES;
pub use pqc_kyber::{keypair, KyberError, SecretKey};

Expand Down

0 comments on commit 5bd43f9

Please sign in to comment.