1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2025-02-07 21:22:41 +00:00

chore(core): remove button request from pairing screens

[no changelog]
This commit is contained in:
M1nd3r 2025-02-07 13:42:36 +01:00
parent b4dd6b7005
commit 8b60ba337c
2 changed files with 5 additions and 11 deletions

View File

@ -202,9 +202,9 @@ class PairingContext(Context):
trezorui_api.show_simple(
title="Copy the following",
text=self._get_code_code_entry_str(),
button="Cancel",
),
br_name="pairing_code_entry",
br_code=ButtonRequestType.Other,
br_name=None,
)
async def _show_nfc_screen(self) -> UiResult:
@ -214,9 +214,9 @@ class PairingContext(Context):
trezorui_api.show_simple(
title="NFC Pairing",
text="Move your device close to Trezor",
button="Cancel",
),
br_name="pairing_nfc",
br_code=ButtonRequestType.Other,
br_name=None,
)
async def _show_qr_code_screen(self) -> UiResult:
@ -232,7 +232,7 @@ class PairingContext(Context):
path="",
xpubs=[],
),
br_name="pairing_qr_code",
br_name=None,
br_code=ButtonRequestType.Other,
)

View File

@ -133,8 +133,6 @@ def test_pairing_qr_code(client: Client) -> None:
protocol._read_message(ThpPairingPreparationsFinished)
# QR Code shown
protocol._read_message(ButtonRequest)
protocol._send_message(ButtonAck())
# Read code from "Trezor's display" using debuglink
@ -184,8 +182,6 @@ def test_pairing_code_entry(client: Client) -> None:
cpace_trezor_public_key = cpace_trezor.cpace_trezor_public_key
# Code Entry code shown
protocol._read_message(ButtonRequest)
protocol._send_message(ButtonAck())
pairing_info = client.debug.pairing_info(
thp_channel_id=protocol.channel_id.to_bytes(2, "big")
@ -246,8 +242,6 @@ def _nfc_pairing(client: Client, protocol: ProtocolV2):
protocol._read_message(ThpPairingPreparationsFinished)
# NFC screen shown
protocol._read_message(ButtonRequest)
protocol._send_message(ButtonAck())
nfc_secret_host = random.randbytes(16)
# Read `nfc_secret` and `handshake_hash` from Trezor using debuglink