From 35896a7d6cb68a0f8fb3b2aebbb05eb44f558ca0 Mon Sep 17 00:00:00 2001 From: grdddj Date: Thu, 4 May 2023 14:45:50 +0200 Subject: [PATCH] chore(core): make Suite labeling dialogue more clear --- core/src/apps/misc/cipher_key_value.py | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/core/src/apps/misc/cipher_key_value.py b/core/src/apps/misc/cipher_key_value.py index e65c8e941..0aa93d34b 100644 --- a/core/src/apps/misc/cipher_key_value.py +++ b/core/src/apps/misc/cipher_key_value.py @@ -24,11 +24,20 @@ async def cipher_key_value(ctx: Context, msg: CipherKeyValue) -> CipheredKeyValu encrypt = msg.encrypt decrypt = not msg.encrypt if (encrypt and msg.ask_on_encrypt) or (decrypt and msg.ask_on_decrypt): - if encrypt: - title = "Encrypt value" + # Special case for Trezor Suite, which asks for setting up labels + if msg.key == "Enable labeling?": + title = "SUITE LABELING" + verb = "ENABLE" else: - title = "Decrypt value" - await confirm_action(ctx, "cipher_key_value", title, description=msg.key) + if encrypt: + title = "Encrypt value" + else: + title = "Decrypt value" + verb = "CONFIRM" + + await confirm_action( + ctx, "cipher_key_value", title, description=msg.key, verb=verb + ) node = keychain.derive(msg.address_n)