Skip to content
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
1 change: 1 addition & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ jobs:
tags: ${{ env.IMAGE_NAME }}:${{ github.sha }}
cache-from: type=gha
cache-to: type=gha,mode=max
provenance: false

- name: Install Cosign
uses: sigstore/cosign-installer@v4.0.0
Expand Down
13 changes: 9 additions & 4 deletions proto/engine/v1/engine.proto
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,15 @@ service Controller {

/** Supported algorithms. */
enum Algorithm {
ALGORITHM_UNSPECIFIED = 0;
FROST_ED25519 = 1;
FROST_SCHNORR_SECP256K1 = 2;
CGGMP24_ECDSA_SECP256K1 = 3;
/** FROST with ed25519 curve. Signature shares are 64 raw bytes (r ‖ s). */
FROST_ED25519 = 0;
/** FROST with secp256k1 curve. Signature shares are 64 raw bytes (r ‖ s). */
FROST_SCHNORR_SECP256K1 = 1;
/**
* CGGMP24 protocol with secp256k1 curve. Signature shares
* are r, s, and recovery id.
*/
CGGMP24_ECDSA_SECP256K1 = 2;
Comment on lines +23 to +31
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The enum value changes here are wire-breaking for protobuf: previously FROST_ED25519 was 1, etc., and now those meanings are shifted onto 0/1/2. Any existing clients/servers built against the previous .proto (and any persisted numeric values, e.g. algorithm stored in Redis metadata) will be misinterpreted. In proto3, it’s also strongly recommended to keep a 0-value like ALGORITHM_UNSPECIFIED to avoid “missing field defaults to a real algorithm”. Consider restoring ALGORITHM_UNSPECIFIED = 0 and keeping existing numeric values stable, adding these doc comments without renumbering.

Suggested change
/** FROST with ed25519 curve. Signature shares are 64 raw bytes (r ‖ s). */
FROST_ED25519 = 0;
/** FROST with secp256k1 curve. Signature shares are 64 raw bytes (r ‖ s). */
FROST_SCHNORR_SECP256K1 = 1;
/**
* CGGMP24 protocol with secp256k1 curve. Signature shares
* are r, s, and recovery id.
*/
CGGMP24_ECDSA_SECP256K1 = 2;
/** Default value for unset or unknown algorithm selections. */
ALGORITHM_UNSPECIFIED = 0;
/** FROST with ed25519 curve. Signature shares are 64 raw bytes (r ‖ s). */
FROST_ED25519 = 1;
/** FROST with secp256k1 curve. Signature shares are 64 raw bytes (r ‖ s). */
FROST_SCHNORR_SECP256K1 = 2;
/**
* CGGMP24 protocol with secp256k1 curve. Signature shares
* are r, s, and recovery id.
*/
CGGMP24_ECDSA_SECP256K1 = 3;

Copilot uses AI. Check for mistakes.
}

message GenerateKeyRequest {
Expand Down
7 changes: 3 additions & 4 deletions src/grpc/grpc.types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,9 @@ import { type Observable } from "rxjs";
* Use numeric values so they serialize correctly over gRPC.
*/
enum Algorithm {
ALGORITHM_UNSPECIFIED = 0,
FROST_ED25519 = 1,
FROST_SCHNORR_SECP256K1 = 2,
CGGMP24_ECDSA_SECP256K1 = 3,
FROST_ED25519 = 0,
FROST_SCHNORR_SECP256K1 = 1,
CGGMP24_ECDSA_SECP256K1 = 2,
Comment on lines +9 to +11
Copy link

Copilot AI Apr 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Algorithm enum renumbering/removal of ALGORITHM_UNSPECIFIED is a breaking change for the TS codebase: there is an existing reference to Algorithm.ALGORITHM_UNSPECIFIED (e.g. src/tasks/key-generation/key-generation.dto.ts:89) that will now fail to compile. If the intent is only to add docs, keep ALGORITHM_UNSPECIFIED = 0 and preserve the existing numeric assignments; if the intent is to remove/repurpose 0, update all TS references/validation accordingly and plan a migration for any persisted enum values.

Suggested change
FROST_ED25519 = 0,
FROST_SCHNORR_SECP256K1 = 1,
CGGMP24_ECDSA_SECP256K1 = 2,
ALGORITHM_UNSPECIFIED = 0,
FROST_ED25519 = 1,
FROST_SCHNORR_SECP256K1 = 2,
CGGMP24_ECDSA_SECP256K1 = 3,

Copilot uses AI. Check for mistakes.
}

/**
Expand Down
2 changes: 0 additions & 2 deletions src/tasks/key-generation/key-generation.dto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import {
IsEnum,
IsInt,
IsNotEmpty,
IsNotIn,
IsString,
Length,
Matches,
Expand Down Expand Up @@ -86,7 +85,6 @@ class KeyGenerationRequestDto {
})
@IsEnum(Algorithm)
@Validate(ThresholdWithinParticipants)
@IsNotIn([Algorithm.ALGORITHM_UNSPECIFIED])
algorithm: Algorithm;

/**
Expand Down
Loading