Cosmetic changes

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
Pol Henarejos
2022-10-04 16:58:19 +02:00
parent ba4faa9840
commit 2734259c02
2 changed files with 2 additions and 10 deletions

View File

@@ -1,5 +1,3 @@
from fido2.attestation import FidoU2FAttestation
# Test U2F register works with FIDO2 auth
def test_ctap1_register(RegRes):
pass
@@ -8,7 +6,7 @@ def test_ctap1_authenticate(RegRes, AuthRes):
pass
def test_authenticate_ctap1_through_ctap2(device, RegRes):
res = device.doGA(allow_list=[
res = device.doGA(ctap1=False, allow_list=[
{"id": RegRes['res'].attestation_object.auth_data.credential_data.credential_id, "type": "public-key"}
])
assert res['res'].get_response(0).credential_id == RegRes['res'].attestation_object.auth_data.credential_data.credential_id
@@ -18,7 +16,7 @@ def test_authenticate_ctap1_through_ctap2(device, RegRes):
def test_ctap1_authenticate_attestation(MCRes, device):
key_handle = MCRes['res'].attestation_object.auth_data.credential_data.credential_id
if len(key_handle) <= 255:
res = device.doGA(ctap1=True,allow_list=[
res = device.doGA(ctap1=True, allow_list=[
{"id": key_handle, "type": "public-key"}
])
else:

View File

@@ -1,18 +1,12 @@
import os
import pytest
from fido2.ctap import CtapError
from fido2.ctap2.pin import PinProtocolV1
from fido2.client import ClientPin
from fido2.webauthn import UserVerificationRequirement
from fido2.utils import hmac_sha256
from utils import *
@pytest.fixture(scope="class")
def client_pin(resetdevice):
return ClientPin(resetdevice.client()._backend.ctap2)
def test_lockout(device, resetdevice, client_pin):
pin = "TestPin"
client_pin.set_pin(pin)