diff --git a/src/key.rs b/src/key.rs index b1c9d05379b..b071d324a9c 100644 --- a/src/key.rs +++ b/src/key.rs @@ -76,6 +76,7 @@ pub enum Kind { BrainpoolP384R1, BrainpoolP512R1, X255, + Secp256k1, } bitflags::bitflags! { @@ -221,6 +222,7 @@ impl Kind { Kind::BrainpoolP256R1 => 12, Kind::BrainpoolP384R1 => 13, Kind::BrainpoolP512R1 => 14, + Kind::Secp256k1 => 15, } } @@ -240,6 +242,7 @@ impl Kind { 12 => Kind::BrainpoolP256R1, 13 => Kind::BrainpoolP384R1, 14 => Kind::BrainpoolP512R1, + 15 => Kind::Secp256k1, _ => return Err(Error::InvalidSerializedKey), }) } diff --git a/src/types.rs b/src/types.rs index 8c533760ff5..b0abbe968db 100644 --- a/src/types.rs +++ b/src/types.rs @@ -425,6 +425,8 @@ pub enum Mechanism { BrainpoolP384R1Prehashed, BrainpoolP512R1, BrainpoolP512R1Prehashed, + Secp256k1, + Secp256k1Prehashed, // clients can also do hashing by themselves Sha256, Tdes,