From 6c1e18e8dad6e418217097d003b4f810aea185a6 Mon Sep 17 00:00:00 2001 From: xiaoguang Date: Mon, 9 Oct 2023 11:29:19 +0800 Subject: [PATCH] fix: modify LC_MAX to 229 --- imkey-core/ikc-common/src/apdu.rs | 2 +- imkey-core/ikc-common/src/constants.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/imkey-core/ikc-common/src/apdu.rs b/imkey-core/ikc-common/src/apdu.rs index 8dffa743..3b6081c5 100644 --- a/imkey-core/ikc-common/src/apdu.rs +++ b/imkey-core/ikc-common/src/apdu.rs @@ -448,7 +448,7 @@ impl Apdu { (data.len() as u32 - LC_MAX as u32 * (size - 1 as u32)) as u8, ) } else { - (0x00, 0xEF) + (0x00, 0xE5) }; let apdu_header = ApduHeader::new(0x80, ins, p1, p2, lc); apdu.extend(apdu_header.to_array().iter()); diff --git a/imkey-core/ikc-common/src/constants.rs b/imkey-core/ikc-common/src/constants.rs index a5e08030..befc359a 100644 --- a/imkey-core/ikc-common/src/constants.rs +++ b/imkey-core/ikc-common/src/constants.rs @@ -14,7 +14,7 @@ pub const TSM_ACTION_COS_UPGRADE: &str = "/seCosUpdate"; pub const TSM_ACTION_COS_CHECK_UPDATE: &str = "/cosCheckUpdate"; //apud related constant -pub const LC_MAX: u32 = 239; +pub const LC_MAX: u32 = 229; pub const ETH_AID: &str = "695F657468"; pub const EOS_AID: &str = "695F656F73";