Abstract attestation support
This commit is contained in:
8
src/env/tock/mod.rs
vendored
8
src/env/tock/mod.rs
vendored
@@ -16,8 +16,8 @@ pub use self::storage::{TockStorage, TockUpgradeStorage};
|
||||
use crate::api::connection::{HidConnection, SendOrRecvError, SendOrRecvResult, SendOrRecvStatus};
|
||||
use crate::api::customization::{CustomizationImpl, DEFAULT_CUSTOMIZATION};
|
||||
use crate::api::firmware_protection::FirmwareProtection;
|
||||
use crate::api::key_store;
|
||||
use crate::api::user_presence::{UserPresence, UserPresenceError, UserPresenceResult};
|
||||
use crate::api::{attestation_store, key_store};
|
||||
use crate::clock::{ClockInt, KEEPALIVE_DELAY_MS};
|
||||
use crate::env::Env;
|
||||
use core::cell::Cell;
|
||||
@@ -195,12 +195,14 @@ impl FirmwareProtection for TockEnv {
|
||||
}
|
||||
|
||||
impl key_store::Helper for TockEnv {}
|
||||
impl attestation_store::Helper for TockEnv {}
|
||||
|
||||
impl Env for TockEnv {
|
||||
type Rng = TockRng256;
|
||||
type UserPresence = Self;
|
||||
type Storage = TockStorage;
|
||||
type KeyStore = Self;
|
||||
type AttestationStore = Self;
|
||||
type UpgradeStorage = TockUpgradeStorage;
|
||||
type FirmwareProtection = Self;
|
||||
type Write = Console;
|
||||
@@ -223,6 +225,10 @@ impl Env for TockEnv {
|
||||
self
|
||||
}
|
||||
|
||||
fn attestation_store(&mut self) -> &mut Self {
|
||||
self
|
||||
}
|
||||
|
||||
fn upgrade_storage(&mut self) -> Option<&mut Self::UpgradeStorage> {
|
||||
self.upgrade_storage.as_mut()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user