From 3e5b62aab35f237e244caf96b409e3c917c2a694 Mon Sep 17 00:00:00 2001 From: bunnie Date: Thu, 15 Jan 2026 16:56:43 +0800 Subject: [PATCH 1/8] Add production public key to the first key slot --- libs/bao1x-api/src/pubkeys/bao1.rs | 33 +++++++++++++++++++++--------- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/libs/bao1x-api/src/pubkeys/bao1.rs b/libs/bao1x-api/src/pubkeys/bao1.rs index ed9c64a7b..d4e39f684 100644 --- a/libs/bao1x-api/src/pubkeys/bao1.rs +++ b/libs/bao1x-api/src/pubkeys/bao1.rs @@ -1,18 +1,31 @@ -/// ===== PLACEHOLDER - bao1 signing HSM ceremony pending ====== -#[allow(unused_imports)] use super::*; use crate::signatures::Pubkey; -/// Bao1 public key. Will be extracted from signing/bao1_id_ed25519_sk using extract_sk_credential.py -pub const ID_ED25519_SK_PUB: [u8; 32] = [0u8; 32]; +/// Bao1 public key. Extracted from signing/bao1_id_ed25519_sk using extract_sk_credential.py +pub const ID_ED25519_SK_PUB: [u8; 32] = [ + 0xa8, 0x7a, 0x5f, 0x98, 0xda, 0xab, 0xfb, 0x51, 0x2f, 0xc3, 0xc2, 0xe5, 0x74, 0x9b, 0x3b, 0xeb, 0x19, + 0x23, 0x88, 0xd2, 0x01, 0x60, 0xa7, 0xdd, 0x58, 0x88, 0xfb, 0x9d, 0xa4, 0x09, 0x52, 0x3a, +]; /// Bao1 public key "key handle" -pub const ID_ED25519_SK_CRED_ID: [u8; 241] = [0u8; 241]; +pub const ID_ED25519_SK_CRED_ID: [u8; 241] = [ + 0x01, 0x51, 0x65, 0x4a, 0xc1, 0x45, 0x55, 0xa9, 0x8e, 0xd8, 0xd5, 0x32, 0x78, 0x80, 0x01, 0xb9, 0x25, + 0xd6, 0x5f, 0xeb, 0xc9, 0xdb, 0x15, 0x6c, 0x4a, 0x1f, 0xa5, 0xf4, 0xcf, 0x1b, 0xcc, 0xa8, 0xf4, 0xa2, + 0x5e, 0xd7, 0xf7, 0xc8, 0xc4, 0x61, 0xeb, 0x8a, 0x16, 0xd9, 0xf8, 0x5b, 0x0e, 0xd1, 0x9b, 0x35, 0x12, + 0x71, 0xfa, 0x89, 0x66, 0x2f, 0xe1, 0x53, 0xf1, 0xda, 0x9a, 0xaf, 0x9a, 0xbd, 0xf5, 0x13, 0xe8, 0xd7, + 0xaa, 0xea, 0xf3, 0x93, 0x70, 0x77, 0x58, 0x91, 0xfd, 0xab, 0x3a, 0x3e, 0xcd, 0x38, 0x9a, 0xcd, 0x2d, + 0x00, 0x73, 0x7d, 0x2d, 0xf3, 0x10, 0xdd, 0x6a, 0x82, 0x80, 0x35, 0xd8, 0x83, 0xbe, 0x01, 0x2d, 0x80, + 0x98, 0x3b, 0xa3, 0x89, 0xba, 0x70, 0x64, 0xa9, 0x81, 0xa7, 0x8a, 0xb3, 0x28, 0xdd, 0x63, 0x46, 0xbf, + 0x00, 0x06, 0xf5, 0x17, 0x53, 0xd6, 0x0e, 0x7e, 0xce, 0xcd, 0x3a, 0x89, 0xb0, 0x87, 0x34, 0x59, 0x89, + 0x29, 0x8b, 0x9b, 0x7b, 0xd6, 0xea, 0xe4, 0x3f, 0x66, 0x92, 0xdc, 0xaf, 0x98, 0x1f, 0xad, 0x02, 0xe0, + 0xab, 0x88, 0x6c, 0x89, 0x56, 0x42, 0x26, 0xc9, 0x66, 0x49, 0x50, 0xee, 0xca, 0x38, 0x61, 0x61, 0xdb, + 0x84, 0xbd, 0x63, 0xd0, 0x46, 0x6b, 0x66, 0xdf, 0x59, 0xf2, 0xe1, 0xf9, 0xba, 0xfb, 0x0c, 0xb9, 0x60, + 0xbc, 0x9a, 0x4d, 0x2f, 0xb2, 0x0f, 0xc1, 0xb1, 0xb3, 0xb0, 0xc9, 0xeb, 0x5c, 0x3a, 0x41, 0x88, 0x56, + 0x58, 0x03, 0xe4, 0x85, 0xe5, 0xac, 0xc0, 0x6d, 0x15, 0xfe, 0xc1, 0xde, 0x98, 0x69, 0xb4, 0x0c, 0x61, + 0x05, 0xf0, 0x13, 0xab, 0xbd, 0x71, 0xc7, 0x0a, 0x22, 0x11, 0xec, 0xf0, 0x8a, 0xe3, 0xf3, 0x85, 0x90, + 0x83, 0xe9, 0x03, +]; /// Bao1 public key "relying party" pub const ID_ED25519_SK_RP: &'static str = "ssh:"; -pub const PUBKEY: Pubkey = Pubkey { - pk: ID_ED25519_SK_PUB, - // Placeholder: tag is 0. - tag: [0u8; 4], // *KEYSLOT_INITIAL_TAGS[BAO1_KEY_SLOT], -}; +pub const PUBKEY: Pubkey = Pubkey { pk: ID_ED25519_SK_PUB, tag: *KEYSLOT_INITIAL_TAGS[BAO1_KEY_SLOT] }; From a5a6cc8e48c36a6c610bf35ccb9e621ca3ba2b31 Mon Sep 17 00:00:00 2001 From: bunnie Date: Thu, 15 Jan 2026 16:57:27 +0800 Subject: [PATCH 2/8] Fix comments in production key 2 slot --- libs/bao1x-api/src/pubkeys/bao2.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/libs/bao1x-api/src/pubkeys/bao2.rs b/libs/bao1x-api/src/pubkeys/bao2.rs index be2d55936..a782f60e6 100644 --- a/libs/bao1x-api/src/pubkeys/bao2.rs +++ b/libs/bao1x-api/src/pubkeys/bao2.rs @@ -1,9 +1,7 @@ -/// ===== PLACEHOLDER - bao2 signing HSM ceremony pending ====== -#[allow(unused_imports)] use super::*; use crate::signatures::Pubkey; -/// Bao1 public key. Will be extracted from signing/bao1_id_ed25519_sk using extract_sk_credential.py +/// Bao2 public key. Extracted from signing/bao2_id_ed25519_sk using extract_sk_credential.py pub const ID_ED25519_SK_PUB: [u8; 32] = [ 0x79, 0x13, 0x5d, 0xc6, 0x67, 0xaf, 0xf4, 0xf7, 0xd3, 0x52, 0xb9, 0x03, 0x28, 0x78, 0x8e, 0xbf, 0x92, 0xc7, 0x86, 0x78, 0x21, 0x38, 0xb3, 0x77, 0x37, 0x0b, 0x15, 0x19, 0x4e, 0x31, 0x28, 0x88, From bf721e3b5cf883b3abfbc9e337d81d690fdded66 Mon Sep 17 00:00:00 2001 From: bunnie Date: Thu, 15 Jan 2026 16:58:22 +0800 Subject: [PATCH 3/8] adjust permissions on serial number; make chip init more permissive It is not clear if I can get the factory to burn the serial number (wafer lot, ID, x/y location) into the location I want it to be. So, I am allowing this to be updated by the firmware on boot, thus necessitating the permissions to be writeable for the serial number field. Furthermore, if there is any error in initializing the chip's identity in the factory, right now the chip goes into a mode where it has crashed and can't run diagnostic code. Write errors in this stage are thus turned into .ok() instead of .unwrap() because we want to allow the chip to go through the whole flow and then diagnose any issues later on. --- bao1x-boot/blobs/ac-block-0x3dc000.bin | Bin 32 -> 32 bytes bao1x-boot/boot1/src/platform/bao1x/slots.rs | 12 ++++++++---- libs/bao1x-api/src/offsets/common.rs | 2 +- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/bao1x-boot/blobs/ac-block-0x3dc000.bin b/bao1x-boot/blobs/ac-block-0x3dc000.bin index 73552f63173b9cb58669d5c51533ccee7e0b1ace..2679947d1509f14b05a44eebb5e831ed095051f0 100644 GIT binary patch literal 32 QcmZQzKm|+;9~h7^03L7y$p8QV literal 32 RcmZQ#_`rY+n1Fm_3;;UN1iJtL diff --git a/bao1x-boot/boot1/src/platform/bao1x/slots.rs b/bao1x-boot/boot1/src/platform/bao1x/slots.rs index 995fcbf87..9f313bf9f 100644 --- a/bao1x-boot/boot1/src/platform/bao1x/slots.rs +++ b/bao1x-boot/boot1/src/platform/bao1x/slots.rs @@ -43,19 +43,22 @@ pub fn check_slots(board_type: &bao1x_api::BoardTypeCoding) { if slot_mgr.read(&CP_ID).unwrap().iter().all(|&b| b == 0 || b == 0xFF) { let cp_id = unsafe { core::slice::from_raw_parts(IFR_CP_ID_BASE as *const u8, SLOT_ELEMENT_LEN_BYTES) }; - slot_mgr.write(&mut rram, &CP_ID, cp_id.try_into().unwrap()).unwrap(); + // don't fail on write failure - otherwise we get stuck here and can't debug the chip + slot_mgr.write(&mut rram, &CP_ID, cp_id.try_into().unwrap()).ok(); } // this one may allocate a TRNG, which takes >50 ms to warm up. if slot_mgr.read(&SERIAL_NUMBER).unwrap().iter().all(|&b| b == 0 || b == 0xFF) { let trng = maybe_trng.get_or_insert_with(|| super::trng::ManagedTrng::new(&board_type)); let k = trng.generate_key(); - slot_mgr.write(&mut rram, &SERIAL_NUMBER, &k).unwrap(); + // don't fail on write failure - otherwise we get stuck here and can't debug the chip + slot_mgr.write(&mut rram, &SERIAL_NUMBER, &k).ok(); } if slot_mgr.read(&UUID).unwrap().iter().all(|&b| b == 0 || b == 0xFF) { let trng = maybe_trng.get_or_insert_with(|| super::trng::ManagedTrng::new(&board_type)); let k = trng.generate_key(); - slot_mgr.write(&mut rram, &UUID, &k).unwrap(); + // don't fail on write failure - otherwise we get stuck here and can't debug the chip + slot_mgr.write(&mut rram, &UUID, &k).ok(); } if slot_mgr.read(&IFR_HASH).unwrap().iter().all(|&b| b == 0 || b == 0xFF) { use digest::Digest; @@ -65,7 +68,8 @@ pub fn check_slots(board_type: &bao1x_api::BoardTypeCoding) { unsafe { core::slice::from_raw_parts(bao1x_api::IFR_BASE as *const u8, bao1x_api::IFR_LEN) }; hasher.update(&ifr_slice); let digest = hasher.finalize(); - slot_mgr.write(&mut rram, &IFR_HASH, digest.as_slice().try_into().unwrap()).unwrap(); + // don't fail on write failure - otherwise we get stuck here and can't debug the chip + slot_mgr.write(&mut rram, &IFR_HASH, digest.as_slice().try_into().unwrap()).ok(); } // once all values are written, advance the CP_BOOT_SETUP_DONE state // safety: the offset is correct because we're pulling it from our pre-defined constants and diff --git a/libs/bao1x-api/src/offsets/common.rs b/libs/bao1x-api/src/offsets/common.rs index 364941872..96e3571dc 100644 --- a/libs/bao1x-api/src/offsets/common.rs +++ b/libs/bao1x-api/src/offsets/common.rs @@ -191,7 +191,7 @@ pub const BOOT0_REVOCATION_OFFSET: usize = BOOT1_REVOCATION_OFFSET + PUBKEY_SLOT /// nor does it have any guarantee of being a monotonic or smoothly spaced out. It could /// even be all zeros (in which case LOT_CODE should be used). However, nominally, the plan /// is for SERIAL_NUMBER to be exactly the CP_ID field. -pub const SERIAL_NUMBER: SlotIndex = SlotIndex::Data(0, PartitionAccess::All, RwPerms::ReadOnly); +pub const SERIAL_NUMBER: SlotIndex = SlotIndex::Data(0, PartitionAccess::Open, RwPerms::ReadWrite); /// `UUID` is a 256-bit random number that can be used as a UUID for the chip. It is publicly /// readable and generated by a TRNG. This is suitable for putting into a KDF and generating From aab774368b74b769ba04fc424acb23452651a200 Mon Sep 17 00:00:00 2001 From: bunnie Date: Thu, 15 Jan 2026 17:02:34 +0800 Subject: [PATCH 4/8] version bump on fido signer tool --- signing/fido-signer/Cargo.lock | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/signing/fido-signer/Cargo.lock b/signing/fido-signer/Cargo.lock index d73ad4a3f..9dd427f53 100644 --- a/signing/fido-signer/Cargo.lock +++ b/signing/fido-signer/Cargo.lock @@ -1234,9 +1234,9 @@ dependencies = [ [[package]] name = "xous" -version = "0.9.68" +version = "0.9.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c12a67abde4d3a3dcebcd390b0910e25cf2654b1a34fc3b060e2da98d41cbcff" +checksum = "acaeff6cedd119aa86d1b06fef4e2935bc4b132468a38f3f006b5574018ba5e2" dependencies = [ "lazy_static", ] From 86f0b18fdcbeec53cbc3682509cd3d6dd2e74e71 Mon Sep 17 00:00:00 2001 From: bunnie Date: Thu, 15 Jan 2026 17:03:06 +0800 Subject: [PATCH 5/8] add the actual raw signing key handles to the repo note that the "sk" is just a handle that points to the residential key on an HSM, so the "private key" contains nothing of cryptographic interest. --- signing/bao1_id_ed25519_sk | 12 ++++++++++++ signing/bao1_id_ed25519_sk.pub | 1 + 2 files changed, 13 insertions(+) create mode 100644 signing/bao1_id_ed25519_sk create mode 100644 signing/bao1_id_ed25519_sk.pub diff --git a/signing/bao1_id_ed25519_sk b/signing/bao1_id_ed25519_sk new file mode 100644 index 000000000..085a98121 --- /dev/null +++ b/signing/bao1_id_ed25519_sk @@ -0,0 +1,12 @@ +-----BEGIN OPENSSH PRIVATE KEY----- +b3BlbnNzaC1rZXktdjEAAAAABG5vbmUAAAAEbm9uZQAAAAAAAAABAAAASgAAABpzay1zc2 +gtZWQyNTUxOUBvcGVuc3NoLmNvbQAAACCoel+Y2qv7US/DwuV0mzvrGSOI0gFgp91YiPud +pAlSOgAAAARzc2g6AAABaCSBXfkkgV35AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY2 +9tAAAAIKh6X5jaq/tRL8PC5XSbO+sZI4jSAWCn3ViI+52kCVI6AAAABHNzaDoBAAAA8QFR +ZUrBRVWpjtjVMniAAbkl1l/rydsVbEofpfTPG8yo9KJe1/fIxGHrihbZ+FsO0Zs1EnH6iW +Yv4VPx2pqvmr31E+jXqurzk3B3WJH9qzo+zTiazS0Ac30t8xDdaoKANdiDvgEtgJg7o4m6 +cGSpgaeKsyjdY0a/AAb1F1PWDn7OzTqJsIc0WYkpi5t71urkP2aS3K+YH60C4KuIbIlWQi +bJZklQ7so4YWHbhL1j0EZrZt9Z8uH5uvsMuWC8mk0vsg/BsbOwyetcOkGIVlgD5IXlrMBt +Ff7B3phptAxhBfATq71xxwoiEezwiuPzhZCD6QMAAAAAAAAAFWJ1bm5pZUBidW5uaWUtZG +Vza3RvcAECAw== +-----END OPENSSH PRIVATE KEY----- diff --git a/signing/bao1_id_ed25519_sk.pub b/signing/bao1_id_ed25519_sk.pub new file mode 100644 index 000000000..0ef2af423 --- /dev/null +++ b/signing/bao1_id_ed25519_sk.pub @@ -0,0 +1 @@ +sk-ssh-ed25519@openssh.com AAAAGnNrLXNzaC1lZDI1NTE5QG9wZW5zc2guY29tAAAAIKh6X5jaq/tRL8PC5XSbO+sZI4jSAWCn3ViI+52kCVI6AAAABHNzaDo= bunnie@bunnie-desktop From b06c124b3ec9bb8b4ea73470a3cff3582a02bb06 Mon Sep 17 00:00:00 2001 From: bunnie Date: Thu, 15 Jan 2026 17:04:11 +0800 Subject: [PATCH 6/8] add a routine to print the info region The info region is a region of RRAM that is used to configure the chip - boot security, what CPUs can run, access control lists, etc. There's no secrets in here, but it's very helpful to inspect for audits and correctness of configuration, so a routine is added to print it in boot1. --- bao1x-boot/boot1/src/repl.rs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/bao1x-boot/boot1/src/repl.rs b/bao1x-boot/boot1/src/repl.rs index e10d31f13..94f36d887 100644 --- a/bao1x-boot/boot1/src/repl.rs +++ b/bao1x-boot/boot1/src/repl.rs @@ -557,6 +557,14 @@ impl Repl { let mut rcurst = CSR::new(utra::sysctrl::HW_SYSCTRL_BASE as *mut u32); rcurst.wo(utra::sysctrl::SFR_RCURST0, 0x55AA); } + "ifr" => { + // safety: the IFR region is aligned and exists here. It is sealed by hardware in USER mode, + // and should report as all 0's. + let ifr = unsafe { core::slice::from_raw_parts(0x6040_0000 as *const u8, 0x400) }; + for (i, chunk) in ifr.chunks(32).enumerate() { + crate::println!(" {:03x}: {:02x?}", i * 32, chunk); + } + } #[cfg(feature = "test-boot0-keys")] "publock" => { let rram = CSR::new(utra::rrc::HW_RRC_BASE as *mut u32); @@ -655,7 +663,7 @@ impl Repl { _ => { crate::println!("Command not recognized: {}", cmd); crate::print!( - "Commands include: reset, echo, altboot, boot, bootwait, idmode, localecho, uf2, boardtype, audit, lockdown, paranoid, self_destruct" + "Commands include: reset, echo, altboot, boot, bootwait, idmode, localecho, uf2, boardtype, audit, lockdown, paranoid, self_destruct, ifr" ); #[cfg(feature = "test-boot0-keys")] crate::print!(", publock"); From 6eda3925ae250e540029f2de7529602f6e28c416 Mon Sep 17 00:00:00 2001 From: bunnie Date: Fri, 16 Jan 2026 00:51:18 +0800 Subject: [PATCH 7/8] update fuse blocks --- bao1x-boot/blobs/ifr_0x180_rv_only.bin | Bin 32 -> 32 bytes bao1x-boot/blobs/ifr_0xc0.bin | Bin 32 -> 32 bytes bao1x-boot/blobs/pubkey-block-0x3e0080.bin | Bin 128 -> 128 bytes bao1x-boot/blobs/pubkey-block-ifr-0x1a0.bin | Bin 0 -> 128 bytes 4 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 bao1x-boot/blobs/pubkey-block-ifr-0x1a0.bin diff --git a/bao1x-boot/blobs/ifr_0x180_rv_only.bin b/bao1x-boot/blobs/ifr_0x180_rv_only.bin index 7d6ef38a3be218b1201f6b080369893d140d0385..7f1b68a646e2bee1f9e728ad80c3093a4ca1c984 100644 GIT binary patch delta 6 NcmY#Tm>|z+1pov;0V@Ci delta 6 NcmY#Tm>|!{000C90Pz3- diff --git a/bao1x-boot/blobs/ifr_0xc0.bin b/bao1x-boot/blobs/ifr_0xc0.bin index dc6c5c3d1da8f243a803cbb4149a199eb2639c15..10dc752fc66580cc9403adb40d0d03be0c35adf4 100644 GIT binary patch delta 6 NcmY#Tm>|z+1pov;0V@Ci delta 6 NcmY#Tm>|!{000C90Pz3- diff --git a/bao1x-boot/blobs/pubkey-block-0x3e0080.bin b/bao1x-boot/blobs/pubkey-block-0x3e0080.bin index d8ca8992408f2271f878d1700cbe4c0195279982..35b3486badbc5b1a3299ba3ff98a361548bd52bb 100644 GIT binary patch delta 40 ycmV+@0N4M30e}G@sCr+R+N=9fFT=v+belWt86$|&0br-yScv*_nBZ$%gV5i+!i2I$S2~s+F6J5q>t zc#gl4$A)+zIJ0**3l$koF(^8KmzgQ;&`v-SOH#_|u2iy1-}fqeiU3SO23yfUAb2_) io9g2#>d18m!GM%Fe*YYFVM2nh{ee>0aWyXAKUg}`nmpeC literal 0 HcmV?d00001 From 341c2353ab25aa14f0bca1487b447cfb46771f17 Mon Sep 17 00:00:00 2001 From: bunnie Date: Fri, 16 Jan 2026 00:52:01 +0800 Subject: [PATCH 8/8] add audit of boot mode to audit and security assessment Turns out we *can* check this at run-time. I thought originally once the chip was sealed these became hidden. I was wrong. So, this means we can actually test to confirm that production was done correctly and in fact the CM7 and debug ports are sealed off. this adds that test. --- bao1x-boot/boot1/src/repl.rs | 11 +++++++++++ bao1x-boot/boot1/src/secboot.rs | 16 ++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/bao1x-boot/boot1/src/repl.rs b/bao1x-boot/boot1/src/repl.rs index 94f36d887..09f6e3080 100644 --- a/bao1x-boot/boot1/src/repl.rs +++ b/bao1x-boot/boot1/src/repl.rs @@ -438,6 +438,17 @@ impl Repl { } else { crate::println!("In-system keys have been generated"); } + let ifr = unsafe { core::slice::from_raw_parts(0x6040_0180 as *const u8, 0x10) }; + let ref_value = [ + 0x00u8, 0x00, 0x00, 0x00, 0x82, 0x8c, 0x42, 0x6a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, + ]; + if ifr == &ref_value { + crate::println!("CM7 & debug confirmed fused off"); + } else { + crate::println!("Factory configuration error - CM7 or debug is enabled!"); + secure = false; + } if !secure { crate::println!("** System did not meet minimum requirements for security **"); } diff --git a/bao1x-boot/boot1/src/secboot.rs b/bao1x-boot/boot1/src/secboot.rs index 4927bfc16..4bcf6a976 100644 --- a/bao1x-boot/boot1/src/secboot.rs +++ b/bao1x-boot/boot1/src/secboot.rs @@ -36,6 +36,22 @@ pub fn try_boot(or_die: bool, csprng: &mut Csprng) { if dev2 != 0 { bao1x_hal::sigcheck::erase_secrets(&mut Some(csprng)).inspect_err(|e| crate::println!("{}", e)).ok(); // "ok" because the expected error is a check on logic/configuration bugs, not attacks } + bollard!(bao1x_hal::sigcheck::die_no_std, 4); + csprng.random_delay(); + { + // check IFR settings - this confirms that the Cortex M7 is disabled, and that hardware JTAG debug is + // disabled + let ifr = unsafe { core::slice::from_raw_parts(0x6040_0180 as *const u8, 0x10) }; + let ref_value = [ + 0x00u8, 0x00, 0x00, 0x00, 0x82, 0x8c, 0x42, 0x6a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + ]; + if ifr != &ref_value { + bao1x_hal::sigcheck::erase_secrets(&mut Some(csprng)) + .inspect_err(|e| crate::println!("{}", e)) + .ok(); // "ok" because the expected error is a check on logic/configuration bugs, not attacks + crate::println!("Incorrect IFR: factory error, or under attack. Secrets erased."); + } + } csprng.random_delay(); let (paranoid1, paranoid2) = one_way.hardened_get2(PARANOID_MODE, PARANOID_MODE_DUPE).unwrap();