Skip to content

Commit 23b1cf8

Browse files
QR code device channel and known devices
1 parent 23d56a0 commit 23b1cf8

File tree

11 files changed

+803
-174
lines changed

11 files changed

+803
-174
lines changed

Cargo.lock

Lines changed: 202 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

libwebauthn/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ byteorder = "1.3.4"
3939
num_enum = "0.7.1"
4040
x509-parser = "0.17.0"
4141
time = "0.3.35"
42+
rustls = { version = "0.23.27", features = ["ring"] }
4243
curve25519-dalek = "4.1.3"
4344
hex = "0.4.3"
4445
mockall = "0.13.1"

libwebauthn/examples/webauthn_cable.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ use std::sync::Arc;
44
use std::time::Duration;
55

66
use libwebauthn::pin::PinRequestReason;
7-
use libwebauthn::transport::cable::channel::CableUxUpdate;
7+
use libwebauthn::transport::cable::channel::{CableUpdate, CableUxUpdate};
88
use libwebauthn::transport::cable::known_devices::{
99
CableKnownDevice, ClientPayloadHint, EphemeralDeviceInfoStore,
1010
};
@@ -75,6 +75,13 @@ async fn handle_updates(mut state_recv: Receiver<CableUxUpdate>) {
7575
}
7676
}
7777
},
78+
CableUxUpdate::CableUpdate(cable_update) => match cable_update {
79+
CableUpdate::ProximityCheck => println!("Proximity check in progress..."),
80+
CableUpdate::Connecting => println!("Connecting to the device..."),
81+
CableUpdate::Authenticating => println!("Authenticating with the device..."),
82+
CableUpdate::Connected => println!("Tunnel established successfully!"),
83+
CableUpdate::Failed => println!("Failed to establish tunnel."),
84+
},
7885
}
7986
}
8087
}

0 commit comments

Comments
 (0)