mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-07-25 16:08:32 +00:00
fix(core): exclude get/set U2F counter from BITCOIN_ONLY
This commit is contained in:
parent
c06a93cba5
commit
729414e606
@ -46,10 +46,6 @@ def find_message_handler_module(msg_type: int) -> str:
|
|||||||
return "apps.management.apply_flags"
|
return "apps.management.apply_flags"
|
||||||
elif msg_type == MessageType.ChangePin:
|
elif msg_type == MessageType.ChangePin:
|
||||||
return "apps.management.change_pin"
|
return "apps.management.change_pin"
|
||||||
elif msg_type == MessageType.SetU2FCounter:
|
|
||||||
return "apps.management.set_u2f_counter"
|
|
||||||
elif msg_type == MessageType.GetNextU2FCounter:
|
|
||||||
return "apps.management.get_next_u2f_counter"
|
|
||||||
elif msg_type == MessageType.SdProtect:
|
elif msg_type == MessageType.SdProtect:
|
||||||
return "apps.management.sd_protect"
|
return "apps.management.sd_protect"
|
||||||
elif msg_type == MessageType.ChangeWipeCode:
|
elif msg_type == MessageType.ChangeWipeCode:
|
||||||
@ -87,6 +83,11 @@ def find_message_handler_module(msg_type: int) -> str:
|
|||||||
if False:
|
if False:
|
||||||
raise RuntimeError
|
raise RuntimeError
|
||||||
|
|
||||||
|
elif msg_type == MessageType.SetU2FCounter:
|
||||||
|
return "apps.management.set_u2f_counter"
|
||||||
|
elif msg_type == MessageType.GetNextU2FCounter:
|
||||||
|
return "apps.management.get_next_u2f_counter"
|
||||||
|
|
||||||
# webauthn
|
# webauthn
|
||||||
elif msg_type == MessageType.WebAuthnListResidentCredentials:
|
elif msg_type == MessageType.WebAuthnListResidentCredentials:
|
||||||
return "apps.webauthn.list_resident_credentials"
|
return "apps.webauthn.list_resident_credentials"
|
||||||
|
@ -14,9 +14,12 @@
|
|||||||
# You should have received a copy of the License along with this library.
|
# You should have received a copy of the License along with this library.
|
||||||
# If not, see <https://www.gnu.org/licenses/lgpl-3.0.html>.
|
# If not, see <https://www.gnu.org/licenses/lgpl-3.0.html>.
|
||||||
|
|
||||||
|
import pytest
|
||||||
|
|
||||||
from trezorlib import fido
|
from trezorlib import fido
|
||||||
|
|
||||||
|
|
||||||
|
@pytest.mark.altcoin
|
||||||
def test_u2f_counter(client):
|
def test_u2f_counter(client):
|
||||||
assert fido.get_next_counter(client) == 0
|
assert fido.get_next_counter(client) == 0
|
||||||
assert fido.get_next_counter(client) == 1
|
assert fido.get_next_counter(client) == 1
|
||||||
|
Loading…
Reference in New Issue
Block a user