1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-17 21:22:10 +00:00

fix(storage): fix app protected check in python implementation

[no changelog]
This commit is contained in:
tychovrahe 2024-01-29 15:04:32 +01:00 committed by TychoVrahe
parent 8147b11345
commit e0594c9c62

View File

@ -210,7 +210,7 @@ class Storage:
raise RuntimeError("Storage locked and app is not public-writable")
def _get_encrypted(self, key: int) -> bytes:
if not consts.is_app_protected(key):
if not consts.is_app_protected(key >> 8):
raise RuntimeError("Only protected values are encrypted")
sat = self.nc.get(consts.SAT_KEY)
if sat is None: