Commit graph

10340 commits

Author SHA1 Message Date
bunnie
8c421c6050
Merge branch 'main' into vault2 2025-11-11 08:47:10 +08:00
bunnie
2b566a3d2e
Merge pull request #726 from betrusted-io/pddb
pddb rework to use the finalized keystore
2025-11-11 08:46:07 +08:00
bunnie
bf7a55640c add baremetal routine to clear the PDDB for testing purposes 2025-11-11 08:43:50 +08:00
bunnie
dd42267eb9 fix mount/format on boot ordering
pddb is working again in hardware, this time with real keys
2025-11-11 08:18:57 +08:00
bunnie
c2c135bfdc fix trng service in baosec environment
fix missing initializers
2025-11-11 07:53:52 +08:00
bunnie
5c98af9dfa fix errors in TRNG setup
- qdiv frac non-zero
- only enable core 0
2025-11-11 07:53:18 +08:00
bunnie
c6d96ec369 Merge branch 'pddb' of github.com:betrusted-io/xous-core into pddb 2025-11-08 09:29:59 +08:00
bunnie
f29391d61d Merge branch 'main' of github.com:betrusted-io/xous-core into pddb 2025-11-08 09:03:52 +08:00
bunnie
e4a4153ff9
Merge branch 'main' into pddb 2025-11-08 09:03:19 +08:00
bunnie
8f859e32c4
Merge pull request #725 from betrusted-io/alt-boot-remap
remap PROG pin to effectively reset for alt-boot mode
2025-11-08 09:02:11 +08:00
bunnie
69c93caadf remap PROG pin to effectively reset for alt-boot mode
this makes it a little easier to explain the procedure in
exiting alt-boot mode
2025-11-08 08:59:19 +08:00
bunnie
82649e683e align hosted environment to current baosec environment
adds a dummy UUID
2025-11-08 04:21:12 +08:00
bunnie
54f476edd3 fixup hosted mode emulation for baosec 2025-11-08 04:20:30 +08:00
bunnie
fa8325c2ed cleanup pddb for gen2 targets
gate out modals entirely from gen2 pddb

passwords in gen2 are now entirely handled outside of the
respective service crates, cleaning up the APIs

some history - on gen1 (precursor) devices, the thesis was to
reduce the amount of distance a password has to travel from
the point of a user entering it to the point of use. I think this
is academically interesting, but it pulls in a lot of code
into each service to manage the passwords, conflating services
with UI layers.

it was a nice experiment.

in gen2 (and hopefully beyond) targets, we now commit to
the idea that something else is passing in the sensitive key
materials. This means that, in fact, keying material has to
transition between process spaces, which increases the attack
surface to recover this. However, it also makes the crates
more portable and maintainable.

This is mitigated partially by the fact that in gen2 targets
the entirety of the code base runs within a piece of silicon,
so "sniffing" (passive observation of data going to memory)
attacks are a good bit harder.
2025-11-08 03:52:39 +08:00
bunnie
792de177b0 implement keystore calls needed for pddb compatibility 2025-11-08 03:52:20 +08:00
bunnie
99769d4622 cleanup the keystore api 2025-11-08 03:52:03 +08:00
bunnie
308529bd75 cleanup warning 2025-11-08 03:51:42 +08:00
Jeanie
1ee7c62699
Merge branch 'main' into tools-bao_monitor-fixing 2025-11-07 11:15:29 +09:00
Jeanie
f43131babd
Merge pull request #1 from betrusted-io/tools-bao_monitor-fixing
ignore the .venv directory
2025-11-07 11:14:31 +09:00
bunnie
2db7b36aeb ignore the .venv directory
i think the venv directory should be local to each install and not
committed to gh?
2025-11-07 08:14:30 +08:00
bunnie
a7a5081d57
Merge pull request #724 from betrusted-io/fix-susres
fix susres on precursor
2025-11-07 08:04:33 +08:00
bunnie
be065c970f
Merge branch 'main' into tools-bao_monitor-fixing 2025-11-07 08:04:10 +08:00
bunnie
d754b86769 fix susres on precursor
heap can't be initialized before suspend/resume is checked

bao1x doesn't have suspend/resume, and requires heap early
on to check signatures

so heap initializationg is now optionally included in two
locations to meet the conflicting requirements per platform.
2025-11-07 08:01:31 +08:00
bunnie
0577ba6775
Merge pull request #723 from betrusted-io/fix-warnings
Fix warnings
2025-11-07 00:41:03 +08:00
bunnie
5981d7afe4 make heap a standard feature available in precursor
this makes the env building uniform across platforms
2025-11-07 00:37:36 +08:00
bunnie
50962a6ba6 cleanup warning in latest rust
pointers to font tables are conjured out of thin air and
the standards have changed on how to do this.
2025-11-07 00:36:57 +08:00
bunnie
f70f900f30
Merge pull request #722 from betrusted-io/serial-numbers
Serial numbers
2025-11-06 14:13:13 +08:00
bunnie
ede73b802f update lockfile 2025-11-06 14:11:00 +08:00
bunnie
815621d829 update handling of id numbers 2025-11-06 14:10:38 +08:00
bunnie
d91c2e7671 fix API to reflect that the 0-state is the most permissive state 2025-11-06 14:10:00 +08:00
bunnie
12d0728582 shorten the generic identifier
make it long enough that it's unlikely to have two identical
ones randomly connected to the same machine

but short enough that it's likely/conceivable to have a collision
2025-11-06 14:08:48 +08:00
bunnie
2d7ee0c614 ensure security bits are set according to -A1 stepping
in some modes these don't get side-effected elsewhere so make
sure they are set correctly upon entering the next stage
2025-11-06 14:08:05 +08:00
bunnie
664ef0a6c4 use serial numbers & interim pid/vid in USB stack 2025-11-06 14:07:30 +08:00
bunnie
8402c601d2 refactor loader to use new env and pass serial #'s to bao-1x envs 2025-11-06 14:02:02 +08:00
bunnie
01efeb49cb refactor env parsing
make it extensible so that more env vars can be added easily
2025-11-06 13:55:21 +08:00
bunnie
e737948a2d add test routine to print environment variables 2025-11-06 13:54:59 +08:00
Jeanie
01239fa981 update readme to reflect changes to monitor flags 2025-11-06 14:53:09 +09:00
bunnie
bab29616aa Merge branch 'main' of github.com:betrusted-io/xous-core into serial-numbers 2025-11-06 13:04:33 +08:00
Jeanie
61a878beca serial monitor more like putty now, and don't have a bunch of unused flags 2025-11-05 23:39:44 +09:00
bunnie
137c70a629 add routines for manipulating and using the serial numbers in boot1 context 2025-11-04 13:15:28 +08:00
bunnie
aaf1cbd2f9 add base routines for deriving & controlling serial numbers 2025-11-04 13:13:52 +08:00
bunnie
1d644d9d33
Merge pull request #720 from rowr111/app-creation-helper
tools-bao: helper for app creation and move all subparsers to their respective command files
2025-11-04 09:34:08 +08:00
Jeanie
9b69e337fb helper for app creation and move all subparsers to their respective command files 2025-11-03 23:39:11 +09:00
bunnie
ef0f7848e7
Merge pull request #719 from betrusted-io/maybe-fix-usb-lockup
Maybe fix usb lockup
2025-11-03 18:35:48 +08:00
bunnie
5863296632 cleanup the feature tree; add double-lock detection printing
this cleans up the feature dependency tree a bit and also adds
some ability to print an error when the double lock condition
is discovered. it should be solved but it can only be detected
at runtime. Insntead of it being a silent failure (because
the server hung in an interrupt context and couldn't emit any characters),
it sets an atomic bool that can be checked and reported upon by
the main thread.

also cleans up debug uart acquisition.
2025-11-03 08:02:21 +08:00
bunnie
0b92da5bab add better locking on core USB object
there is a lock that happens in serial console interactions with
local echo where the instant feedback of a character entered causes
the USB object to be locked when the interrupt handler enters to
receive a character that was just sent.

The fix to this is to add the ability to disable interrupts before
entering a critical section (such as enqueuing data for a write)
and then re-enabling after tha section is done.
2025-11-03 08:00:31 +08:00
bunnie
fe136ff820
Merge branch 'main' into vault2 2025-11-02 10:40:47 +08:00
bunnie
eaef679faa
Merge pull request #717 from betrusted-io/keystore-dabao
Keystore dabao
2025-11-02 10:40:28 +08:00
bunnie
5de6581698 include chaff output into the hazardous-debug 2025-11-02 10:38:29 +08:00
bunnie
ed94245a5c enable trng server in dabao mode
this allows the rand core crates to work
2025-11-02 10:37:47 +08:00