Skip to content

Commit 61415cc

Browse files
authored
Merge pull request #83 from bitfinity-network/cycles_payment_for_ecdsa_sign
Cycles payment for ECDSA signing
2 parents 71cd765 + 57a18aa commit 61415cc

3 files changed

Lines changed: 5 additions & 3 deletions

File tree

src/did/src/error.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ use rlp::DecoderError;
66
use serde::Serialize;
77
use thiserror::Error;
88

9-
use crate::{transaction::BlockId, BlockNumber, H160, U256};
9+
use crate::transaction::BlockId;
10+
use crate::{BlockNumber, H160, U256};
1011

1112
pub type Result<T> = std::result::Result<T, EvmError>;
1213

src/did/src/transaction.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ impl From<EthersSignature> for Signature {
184184
impl Signature {
185185
/// Upper limit for signature S field.
186186
/// See comment to `Signature::check_malleability()` for more details.
187-
pub const S_UPPER_LIMIT_HEX_STR: &str =
187+
pub const S_UPPER_LIMIT_HEX_STR: &'static str =
188188
"0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0";
189189

190190
/// This comment copied from OpenZeppelin `ECDSA::tryRecover()` function.

src/eth-signer/src/ic_sign.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,8 @@ impl IcSigner {
110110
Principal::management_canister(),
111111
"sign_with_ecdsa",
112112
(request,),
113-
SignWithEcdsaResponse
113+
SignWithEcdsaResponse,
114+
100_000_000_000
114115
)
115116
.await
116117
.map_err(|(code, msg)| IcSignerError::SigningFailed(code, msg))?

0 commit comments

Comments
 (0)