feat(trezorlib): add stop_and_connect boot args [no changelog]
What changed, and why it matters
This commit simply adds a new named option in the Trezor Python library that tells a Trezor bootloader to stop at the 'wait for host' screen. There is no bug, no vulnerability, and no security fix visible in the change.
No security action needed; review as normal feature code.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch adds a single classmethod stop_and_connect() to BootArgs in python/src/trezorlib/_internal/bootargs.py. It returns a BootArgs instance using the already-defined BootCommand.STOP_AND_CONNECT. The command itself is not introduced here; only a convenience constructor is added. No logic changes affect firmware behavior, parsing, authentication, or secrets handling.
Changed components
python/src/trezorlib/_internal/bootargs.pyInspect captured patch +5 / −0
### python/src/trezorlib/_internal/bootargs.py
@@ -239,6 +239,11 @@ def none(cls) -> BootArgs:
def stop_and_wait(cls) -> BootArgs:
return cls(BootCommand.STOP_AND_WAIT)
+ @classmethod
+ def stop_and_connect(cls) -> BootArgs:
+ """Stay in the bootloader on the host-waiting screen."""
+ return cls(BootCommand.STOP_AND_CONNECT)
+
@classmethod
def install_upgrade(cls, header_hash: bytes) -> BootArgs:
if len(header_hash) != 32:Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.