Use released dependencies

This commit is contained in:
Robin Krahl
2025-01-10 14:43:39 +01:00
parent 60c58eb806
commit 4fe4e4e287
5 changed files with 21 additions and 27 deletions
Generated
+12 -9
View File
@@ -342,9 +342,9 @@ dependencies = [
[[package]]
name = "ctaphid-app"
version = "0.1.0-rc.1"
version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "d1179116598f4f53694ce2fda6bb38183f71efcb9ff6385d08ca1d79d6254841"
checksum = "1fe93489fe96c998488d0843dffea35c02ed9add2585e55228e1d45988727ecc"
dependencies = [
"heapless-bytes",
"trussed-core",
@@ -352,8 +352,9 @@ dependencies = [
[[package]]
name = "ctaphid-dispatch"
version = "0.1.1"
source = "git+https://github.com/trussed-dev/ctaphid-dispatch.git?rev=5a2864c76fea6785d9ffe4c7b6596237d8378755#5a2864c76fea6785d9ffe4c7b6596237d8378755"
version = "0.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "27caf0a07de6b0af58ba69562c1834ddf7aa27bc1d1687fed3b18fea1501e59e"
dependencies = [
"ctaphid-app",
"delog",
@@ -1489,9 +1490,9 @@ dependencies = [
[[package]]
name = "trussed-core"
version = "0.1.0-rc.1"
version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "fc8831dee63f373a6bb031caac114c6672d593d03e371fd95b41a47be7d415e0"
checksum = "afddad280ae8a5235e1b06408cca909ce9454cdd89f941b94b024c580732b3ce"
dependencies = [
"heapless-bytes",
"littlefs2-core",
@@ -1559,7 +1560,8 @@ checksum = "1f6cc3adc849b5292b4075fc0d5fdcf2f24866e88e336dd27a8943090a520508"
[[package]]
name = "usbd-ccid"
version = "0.3.0"
source = "git+https://github.com/trussed-dev/usbd-ccid?tag=0.3.0#0a31e9cf7c5aa8498c65982c95b9faeebe8e3f52"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "403fefa622483869d1b36f2accd7458291202c18aa2f2e5147caf638825dde0c"
dependencies = [
"delog",
"embedded-time",
@@ -1571,8 +1573,9 @@ dependencies = [
[[package]]
name = "usbd-ctaphid"
version = "0.1.0"
source = "git+https://github.com/trussed-dev/usbd-ctaphid.git?rev=96bf04e97cfc8077b4d9b6b97b3e34ec3ca3e2fc#96bf04e97cfc8077b4d9b6b97b3e34ec3ca3e2fc"
version = "0.2.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "092fad7bf817001ecade9272fe6ccbea4e5d0c02f99ca24c4c5ce97fbbff5371"
dependencies = [
"ctaphid-dispatch",
"delog",
+2 -5
View File
@@ -12,8 +12,8 @@ usb-device = { version = "0.2.7", default-features = false }
usbip-device = "0.1.5"
# ctaphid
ctaphid-dispatch = { version = "0.1", features = ["log-all"], optional = true }
usbd-ctaphid = { version = "0.1", features = ["log-all"], optional = true }
ctaphid-dispatch = { version = "0.2", features = ["log-all"], optional = true }
usbd-ctaphid = { version = "0.2", features = ["log-all"], optional = true }
# ccid
apdu-dispatch = { version = "0.3", optional = true }
@@ -35,6 +35,3 @@ ccid = ["apdu-dispatch", "usbd-ccid"]
[patch.crates-io]
trussed = { git = "https://github.com/trussed-dev/trussed.git", rev = "6bba8fde36d05c0227769eb63345744e87d84b2b" }
usbd-ctaphid = { git = "https://github.com/trussed-dev/usbd-ctaphid.git", rev = "96bf04e97cfc8077b4d9b6b97b3e34ec3ca3e2fc" }
usbd-ccid = { git = "https://github.com/trussed-dev/usbd-ccid", tag = "0.3.0" }
ctaphid-dispatch = { git = "https://github.com/trussed-dev/ctaphid-dispatch.git", rev = "5a2864c76fea6785d9ffe4c7b6596237d8378755" }
+3 -9
View File
@@ -12,10 +12,7 @@ use std::path::PathBuf;
#[cfg(feature = "ccid")]
use apdu_dispatch::command::SIZE as ApduCommandSize;
#[cfg(feature = "ctaphid")]
use ctaphid_dispatch::{
command::{Command, VendorCommand},
types::{AppResult, Error},
};
use ctaphid_dispatch::app::{Command, Error, VendorCommand};
use clap::Parser;
use clap_num::maybe_hex;
@@ -80,7 +77,7 @@ impl<C: Client, const N: usize> ctaphid_dispatch::app::App<'_, N> for DummyApp<C
command: Command,
_request: &[u8],
response: &mut heapless_bytes::Bytes<N>,
) -> AppResult {
) -> Result<(), Error> {
match command {
CTAPHID_COMMAND_RNG => self.rng(response),
_ => return Err(Error::InvalidCommand),
@@ -111,10 +108,7 @@ impl<'a, S: StoreProvider> trussed_usbip::Apps<'a, S, CoreOnly>
fn with_ctaphid_apps<T>(
&mut self,
f: impl FnOnce(
&mut [&mut dyn ctaphid_dispatch::app::App<
'a,
{ ctaphid_dispatch::types::MESSAGE_SIZE },
>],
&mut [&mut dyn ctaphid_dispatch::app::App<'a, { ctaphid_dispatch::MESSAGE_SIZE }>],
) -> T,
) -> T {
f(&mut [&mut self.dummy])
+2 -2
View File
@@ -3,7 +3,7 @@ use std::{
time::{Duration, Instant},
};
use ctaphid_dispatch::dispatch::Dispatch;
use ctaphid_dispatch::Dispatch;
use usb_device::bus::{UsbBus, UsbBusAllocator};
use usbd_ctaphid::{types::Status, CtapHid};
@@ -11,7 +11,7 @@ use super::{Timeout, IS_WAITING};
pub fn setup<'bus, 'pipe, 'interrupt, B: UsbBus>(
bus_allocator: &'bus UsbBusAllocator<B>,
interchange: &'pipe ctaphid_dispatch::types::Channel,
interchange: &'pipe ctaphid_dispatch::Channel,
) -> (
CtapHid<'bus, 'pipe, 'interrupt, B>,
Dispatch<'pipe, 'interrupt>,
+2 -2
View File
@@ -60,7 +60,7 @@ pub trait Apps<'interrupt, S: StoreProvider, D: Dispatch> {
f: impl FnOnce(
&mut [&mut dyn ctaphid_dispatch::app::App<
'interrupt,
{ ctaphid_dispatch::types::MESSAGE_SIZE },
{ ctaphid_dispatch::MESSAGE_SIZE },
>],
) -> T,
) -> T;
@@ -96,7 +96,7 @@ impl<'interrupt, S: StoreProvider, D: Dispatch, A: Apps<'interrupt, S, D>> Runne
let bus_allocator = UsbBusAllocator::new(UsbIpBus::new());
#[cfg(feature = "ctaphid")]
let ctap_channel = ctaphid_dispatch::types::Channel::new();
let ctap_channel = ctaphid_dispatch::Channel::new();
#[cfg(feature = "ctaphid")]
let (mut ctaphid, mut ctaphid_dispatch) = ctaphid::setup(&bus_allocator, &ctap_channel);