OXIESEC PANEL
- Current Dir:
/
/
opt
/
gsutil
/
third_party
/
pyu2f
/
pyu2f
/
__pycache__
Server IP: 2a02:4780:11:1594:0:ef5:22d7:a
Upload:
Create Dir:
Name
Size
Modified
Perms
📁
..
-
02/11/2025 08:19:48 AM
rwxr-xr-x
📄
__init__.cpython-39.pyc
198 bytes
02/11/2025 08:19:48 AM
rw-r--r--
📄
apdu.cpython-39.pyc
3.77 KB
02/11/2025 08:19:48 AM
rw-r--r--
📄
errors.cpython-39.pyc
3.16 KB
02/11/2025 08:19:48 AM
rw-r--r--
📄
hardware.cpython-39.pyc
5.12 KB
02/11/2025 08:19:48 AM
rw-r--r--
📄
hidtransport.cpython-39.pyc
9.66 KB
02/11/2025 08:19:48 AM
rw-r--r--
📄
model.cpython-39.pyc
2.44 KB
02/11/2025 08:19:48 AM
rw-r--r--
📄
u2f.cpython-39.pyc
5.49 KB
02/11/2025 08:19:48 AM
rw-r--r--
Editing: u2f.cpython-39.pyc
Close
a ��a} � @ sp d Z ddlZddlZddlZddlmZ ddlmZ ddlmZ ddlmZ e� � fdd�Z G d d � d e�ZdS )aN Implement a high level U2F API analogous to the javascript API spec. This modules implements a high level U2F API that is analogous in spirit to the high level U2F javascript API. It supports both registration and authetication. For the purposes of this API, the "origin" is the hostname of the machine this library is running on. � N)�errors)�hardware)�hidtransport)�modelc C sN t �� }|D ]4}zttj|d�| d�W S tjy> Y q0 qt�� �dS )zEObtains a U2FInterface for the first valid local U2FHID device found.)� transport)�security_key�originN)r ZDiscoverLocalHIDU2FDevices�U2FInterfacer ZSecurityKeyr �UnsupportedVersionException�NoDeviceFoundError)r Zhid_transports�t� r �*/opt/gsutil/third_party/pyu2f/pyu2f/u2f.py�GetLocalU2FInterface! s �r c @ s8 e Zd ZdZe�� fdd�Zdd� Zdd� Zdd � Z d S )r a� High level U2F interface. Implements a high level interface in the spirit of the FIDO U2F javascript API high level interface. It supports registration and authentication (signing). IMPORTANT NOTE: This class does NOT validate the app id against the origin. In particular, any user can assert any app id all the way to the device. The security model of a python library is such that doing so would not provide significant benfit as it could be bypassed by the caller talking to a lower level of the API. In fact, so could the origin itself. The origin is still set to a plausible value (the hostname) by this library. TODO(gdasher): Figure out a plan on how to address this gap/document the consequences of this more clearly. c C s&