From c5c25b8af9deda3cc3e1e22b015c4203efb4fd3b Mon Sep 17 00:00:00 2001 From: Francois Beutin Date: Mon, 9 Sep 2024 17:47:04 +0200 Subject: [PATCH] Give knowledge of derivation path from eth to plugin --- src/shared_context.h | 5 ----- src_features/signTx/logic_signTx.c | 1 + 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/src/shared_context.h b/src/shared_context.h index 323ffd1779..9a1b49f866 100644 --- a/src/shared_context.h +++ b/src/shared_context.h @@ -26,11 +26,6 @@ extern void common_app_init(void); #define MAX_ASSETS 5 -typedef struct bip32_path_t { - uint8_t length; - uint32_t path[MAX_BIP32_PATH]; -} bip32_path_t; - typedef struct internalStorage_t { bool dataAllowed; bool contractDetails; diff --git a/src_features/signTx/logic_signTx.c b/src_features/signTx/logic_signTx.c index 0d5ac24e7c..e4c8c85bc5 100644 --- a/src_features/signTx/logic_signTx.c +++ b/src_features/signTx/logic_signTx.c @@ -426,6 +426,7 @@ __attribute__((noinline)) static uint16_t finalize_parsing_helper(void) { tmpContent.txContent.value.length = 32; memmove(tmpContent.txContent.destination, pluginFinalize.address, 20); tmpContent.txContent.destinationLength = 20; + memcpy(&tmpContent.txContent.bip32, &tmpCtx.transactionContext.bip32, sizeof(bip32_path_t)); if (pluginProvideInfo.item1 != NULL) { decimals = pluginProvideInfo.item1->token.decimals; ticker = pluginProvideInfo.item1->token.ticker;