messign with leds
This commit is contained in:
parent
41a2ec0e4d
commit
23b09a791a
@ -5,7 +5,7 @@
|
||||
<excludeFolder url="file://$MODULE_DIR$/.venv" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/venv" />
|
||||
</content>
|
||||
<orderEntry type="jdk" jdkName="Python 3.11 (CNSA-276-FP) (2)" jdkType="Python SDK" />
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
@ -3,5 +3,5 @@
|
||||
<component name="Black">
|
||||
<option name="sdkName" value="Python 3.12 (CNSA-276-FP)" />
|
||||
</component>
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.11 (CNSA-276-FP) (2)" project-jdk-type="Python SDK" />
|
||||
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.12 (CNSA-276-FP)" project-jdk-type="Python SDK" />
|
||||
</project>
|
10
main.py
10
main.py
@ -32,7 +32,7 @@ This works with both FIDO 2.0 devices as well as with U2F devices.
|
||||
On Windows, the native WebAuthn API will be used.
|
||||
"""
|
||||
import time
|
||||
|
||||
import RPI.GPIO as GPIO
|
||||
import pickle
|
||||
import psycopg2
|
||||
import fido2.webauthn
|
||||
@ -45,6 +45,8 @@ import ctypes
|
||||
from fido2.ctap2 import Ctap2
|
||||
|
||||
gotAaguid = None
|
||||
GPIO.setmode(GPIO.BCM)
|
||||
GPIO.setup(14, GPIO.OUT)
|
||||
|
||||
class CliInteraction(UserInteraction):
|
||||
def prompt_up(self):
|
||||
@ -181,6 +183,12 @@ while True:
|
||||
|
||||
print("Credential authenticated!")
|
||||
|
||||
for i in range(10):
|
||||
GPIO.output(14, GPIO.HIGH)
|
||||
time.sleep(0.2)
|
||||
GPIO.output(14, GPIO.LOW)
|
||||
time.sleep(0.2)
|
||||
|
||||
print("CLIENT DATA:", result.client_data)
|
||||
print()
|
||||
print("AUTH DATA:", result.authenticator_data)
|
||||
|
Loading…
Reference in New Issue
Block a user