mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-21 09:14:34 +00:00
remove redundant prints in loader
the first check should *never* print a message because an attacker can trigger a glitch off of the UART. this eliminates the diagnostic print on the first check.
This commit is contained in:
parent
0bb693449b
commit
c499087d5a
2 changed files with 7 additions and 2 deletions
|
|
@ -313,8 +313,7 @@ pub unsafe extern "C" fn rust_entry(signed_buffer: *const usize, signature: u32)
|
||||||
}
|
}
|
||||||
bao1x_hal::sigcheck::die_no_std();
|
bao1x_hal::sigcheck::die_no_std();
|
||||||
} else {
|
} else {
|
||||||
println!("{}LOADER.KERNDEV,{}", BOOKEND_START, BOOKEND_END);
|
// don't print anything on the first check, so a double-glitch is harder
|
||||||
println!("Developer key detected on kernel. Proceeding in developer mode!");
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
csprng.random_delay();
|
csprng.random_delay();
|
||||||
|
|
|
||||||
|
|
@ -279,6 +279,12 @@ impl SwapHal {
|
||||||
);
|
);
|
||||||
bao1x_hal::sigcheck::die_no_std();
|
bao1x_hal::sigcheck::die_no_std();
|
||||||
} else {
|
} else {
|
||||||
|
bollard!(bao1x_hal::sigcheck::die_no_std, 4);
|
||||||
|
// check if it's still 0 - force a double-glitch
|
||||||
|
if owc.get(bao1x_api::DEVELOPER_MODE).unwrap() == 0 {
|
||||||
|
bao1x_hal::sigcheck::die_no_std();
|
||||||
|
}
|
||||||
|
bollard!(bao1x_hal::sigcheck::die_no_std, 4);
|
||||||
println!("{}LOADER.SWAPDEV,{}", BOOKEND_START, BOOKEND_END);
|
println!("{}LOADER.SWAPDEV,{}", BOOKEND_START, BOOKEND_END);
|
||||||
println!(
|
println!(
|
||||||
"Developer key detected on swap. Proceeding in developer mode!"
|
"Developer key detected on swap. Proceeding in developer mode!"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue