mirror of
https://github.com/polhenarejos/pico-fido.git
synced 2025-12-19 19:27:41 +08:00
Fixed AUT permission.
Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
@@ -90,7 +90,7 @@ class VendorConfig(Config):
|
|||||||
|
|
||||||
def enable_device_aut(self, ct):
|
def enable_device_aut(self, ct):
|
||||||
self._call(
|
self._call(
|
||||||
Config.CMD.VENDOR_PROTOTYPE,
|
Config.CMD.CONFIG_VENDOR_PROTOTYPE,
|
||||||
{
|
{
|
||||||
VendorConfig.PARAM.VENDOR_COMMAND_ID: VendorConfig.CMD.CONFIG_AUT_ENABLE,
|
VendorConfig.PARAM.VENDOR_COMMAND_ID: VendorConfig.CMD.CONFIG_AUT_ENABLE,
|
||||||
VendorConfig.PARAM.VENDOR_AUT_CT: ct
|
VendorConfig.PARAM.VENDOR_AUT_CT: ct
|
||||||
@@ -99,7 +99,7 @@ class VendorConfig(Config):
|
|||||||
|
|
||||||
def disable_device_aut(self):
|
def disable_device_aut(self):
|
||||||
self._call(
|
self._call(
|
||||||
Config.CMD.VENDOR_PROTOTYPE,
|
Config.CMD.CONFIG_VENDOR_PROTOTYPE,
|
||||||
{
|
{
|
||||||
VendorConfig.PARAM.VENDOR_COMMAND_ID: VendorConfig.CMD.CONFIG_AUT_DISABLE
|
VendorConfig.PARAM.VENDOR_COMMAND_ID: VendorConfig.CMD.CONFIG_AUT_DISABLE
|
||||||
},
|
},
|
||||||
@@ -450,7 +450,7 @@ def main(args):
|
|||||||
dev = next(CtapHidDevice.list_devices(), None)
|
dev = next(CtapHidDevice.list_devices(), None)
|
||||||
ctap = Ctap2Vendor(dev)
|
ctap = Ctap2Vendor(dev)
|
||||||
client_pin = ClientPin(ctap)
|
client_pin = ClientPin(ctap)
|
||||||
token = client_pin.get_pin_token(args.pin)
|
token = client_pin.get_pin_token(args.pin, permissions=ClientPin.PERMISSION.AUTHENTICATOR_CFG)
|
||||||
vdr = Vendor(ctap, pin_uv_protocol=PinProtocolV2(), pin_uv_token=token)
|
vdr = Vendor(ctap, pin_uv_protocol=PinProtocolV2(), pin_uv_token=token)
|
||||||
|
|
||||||
if (args.command == 'secure'):
|
if (args.command == 'secure'):
|
||||||
|
|||||||
Reference in New Issue
Block a user