diff --git a/firmware/fsm.c b/firmware/fsm.c index b4025c5ee6..c0da402483 100644 --- a/firmware/fsm.c +++ b/firmware/fsm.c @@ -671,7 +671,7 @@ void fsm_msgSignIdentity(SignIdentity *msg) const HDNode *node = fsm_getDerivedNode(address_n, 5); if (!node) return; - uint8_t message[128]; + uint8_t message[256 + 256]; memcpy(message, msg->challenge_hidden.bytes, msg->challenge_hidden.size); const int len = strlen(msg->challenge_visual); memcpy(message + msg->challenge_hidden.size, msg->challenge_visual, len); diff --git a/firmware/protob/messages.options b/firmware/protob/messages.options index da0af37c9c..a322f98601 100644 --- a/firmware/protob/messages.options +++ b/firmware/protob/messages.options @@ -86,8 +86,8 @@ EstimateTxSize.coin_name max_size:17 SignTx.coin_name max_size:17 -SignIdentity.challenge_hidden max_size:64 -SignIdentity.challenge_visual max_size:64 +SignIdentity.challenge_hidden max_size:256 +SignIdentity.challenge_visual max_size:256 SignedIdentity.address max_size:36 SignedIdentity.public_key max_size:33 diff --git a/firmware/protob/messages.pb.h b/firmware/protob/messages.pb.h index b56c8d37fa..b867cc947d 100644 --- a/firmware/protob/messages.pb.h +++ b/firmware/protob/messages.pb.h @@ -510,7 +510,7 @@ typedef struct _ResetDevice { typedef struct { size_t size; - uint8_t bytes[64]; + uint8_t bytes[256]; } SignIdentity_challenge_hidden_t; typedef struct _SignIdentity { @@ -519,7 +519,7 @@ typedef struct _SignIdentity { bool has_challenge_hidden; SignIdentity_challenge_hidden_t challenge_hidden; bool has_challenge_visual; - char challenge_visual[64]; + char challenge_visual[256]; } SignIdentity; typedef struct { @@ -975,7 +975,7 @@ extern const pb_field_t DebugLinkLog_fields[4]; #define SimpleSignTx_size (19 + 0*TxInputType_size + 0*TxOutputType_size + 0*TransactionType_size) #define TxRequest_size (18 + TxRequestDetailsType_size + TxRequestSerializedType_size) #define TxAck_size (6 + TransactionType_size) -#define SignIdentity_size (138 + IdentityType_size) +#define SignIdentity_size (524 + IdentityType_size) #define SignedIdentity_size 140 #define FirmwareErase_size 0 #define FirmwareUpload_size 2