Have transcripted versions specify their minor version pre-1.0

This commit is contained in:
Luke Parker 2022-12-27 00:49:31 -05:00
parent bacf31378d
commit 3b4c600c60
No known key found for this signature in database
4 changed files with 4 additions and 4 deletions

View file

@ -1,4 +1,4 @@
c# Ciphersuite # Ciphersuite
Ciphersuites for elliptic curves premised on ff/group. Ciphersuites for elliptic curves premised on ff/group.

View file

@ -123,7 +123,7 @@ impl<Id: Eq + Hash, C: Ciphersuite> Encryption<Id, C> {
fn cipher(&self, participant: Id, encrypt: bool) -> ChaCha20 { fn cipher(&self, participant: Id, encrypt: bool) -> ChaCha20 {
// Ideally, we'd box this transcript with ZAlloc, yet that's only possible on nightly // Ideally, we'd box this transcript with ZAlloc, yet that's only possible on nightly
// TODO: https://github.com/serai-dex/serai/issues/151 // TODO: https://github.com/serai-dex/serai/issues/151
let mut transcript = RecommendedTranscript::new(b"DKG Encryption v0"); let mut transcript = RecommendedTranscript::new(b"DKG Encryption v0.2");
transcript.domain_separate(self.dst); transcript.domain_separate(self.dst);
let other = self.enc_keys[&participant]; let other = self.enc_keys[&participant];

View file

@ -27,7 +27,7 @@ use crate::{
#[allow(non_snake_case)] #[allow(non_snake_case)]
fn challenge<C: Ciphersuite>(context: &str, l: u16, R: &[u8], Am: &[u8]) -> C::F { fn challenge<C: Ciphersuite>(context: &str, l: u16, R: &[u8], Am: &[u8]) -> C::F {
let mut transcript = RecommendedTranscript::new(b"DKG FROST v0"); let mut transcript = RecommendedTranscript::new(b"DKG FROST v0.2");
transcript.domain_separate(b"Schnorr Proof of Knowledge"); transcript.domain_separate(b"Schnorr Proof of Knowledge");
transcript.append_message(b"context", context.as_bytes()); transcript.append_message(b"context", context.as_bytes());
transcript.append_message(b"participant", l.to_le_bytes()); transcript.append_message(b"participant", l.to_le_bytes());

View file

@ -28,7 +28,7 @@ pub trait CiphersuitePromote<C2: Ciphersuite> {
} }
fn transcript<G: GroupEncoding>(key: G, i: u16) -> RecommendedTranscript { fn transcript<G: GroupEncoding>(key: G, i: u16) -> RecommendedTranscript {
let mut transcript = RecommendedTranscript::new(b"DKG Generator Promotion v0"); let mut transcript = RecommendedTranscript::new(b"DKG Generator Promotion v0.2");
transcript.append_message(b"group_key", key.to_bytes()); transcript.append_message(b"group_key", key.to_bytes());
transcript.append_message(b"participant", i.to_be_bytes()); transcript.append_message(b"participant", i.to_be_bytes());
transcript transcript