Commit graph

10340 commits

Author SHA1 Message Date
nworbnhoj
747fb93c58 mtxchat replace EMPTY String with Option<String> 2023-09-13 15:31:23 +10:00
bunnie
06953cec55 remove overly sensitive test case
this case is too sensitive to clock config outside of the PIO
block, because it relies on some specificts of how inter-bus sync
works and the environment is free to set PIO and PCLK relationship
arbitrarily
2023-09-13 10:29:14 +08:00
nworbnhoj
d8db9ad2a7 fix tls::rota.public_key() 2023-09-13 07:20:10 +10:00
nworbnhoj
a06d84d8a9 convert mtxchat to use tls.root_store()
a ureq::Agent is configured to use tls.root_store(), and used for all comms with the matrix server
2023-09-13 07:18:22 +10:00
nworbnhoj
c22419f7c7 bump rustls to harmonize versions 2023-09-13 06:57:39 +10:00
bunnie
b29d29eb0e
Revert "Revert "Tls.probe"" 2023-09-12 19:55:50 +08:00
bunnie
18017beac6
Merge pull request #414 from betrusted-io/revert-409-tls.probe
Revert "Tls.probe"
2023-09-12 19:13:28 +08:00
bunnie
7efcca39d5
Revert "Tls.probe" 2023-09-12 19:13:11 +08:00
bunnie
2e1b3afc8b update pins in lockfile 2023-09-12 16:32:36 +08:00
bunnie
478a612c02 commit version bump 2023-09-12 16:25:10 +08:00
bunnie
3e051fa39e
Merge pull request #411 from betrusted-io/mark-as-slice-as-unsafe
xous: mark MemoryRange::as_slice and friends as unsafe
2023-09-12 16:17:25 +08:00
bunnie
1ebee74bb1
Merge pull request #409 from nworbnhoj/tls.probe
Tls.probe
2023-09-12 16:07:52 +08:00
Sean Cross
5dfad296ae xous: mark MemoryRange::as_slice and friends as unsafe
Mark `MemoryRange::as_slice()` and `MemoryRange::as_slice_mut()` as
unsafe.

This is due to the fact that not all representable types can be cast to
an arbitrary value. For example, if Process A sends random values to
Process B, then Process B casts the memory to a slice of `bool`, then
any values that are not 0 or 1 are undefined.

Because these functions can leak UB into the program, they are marked as
unsafe.

This patch adds `unsafe {}` blocks to all instances where this function
is called. Additionally, all instances have been checked to verify that
they do not cast to any invalid types -- most use `u8` or `u32`.

Additionally, the long-deprecated `MemoryRange::from_parts()` call was
removed, since that causes UB without being marked as unsafe.

Signed-off-by: Sean Cross <sean@xobs.io>
2023-09-12 10:07:38 +08:00
Sean Cross
673ca1c416 xous: mark MemoryRange::as_slice and friends as unsafe
Mark `MemoryRange::as_slice()` and `MemoryRange::as_slice_mut()` as
unsafe.

This is due to the fact that not all representable types can be cast to
an arbitrary value. For example, if Process A sends random values to
Process B, then Process B casts the memory to a slice of `bool`, then
any values that are not 0 or 1 are undefined.

Because these functions can leak UB into the program, they are marked as
unsafe.

This patch adds `unsafe {}` blocks to all instances where this function
is called. Additionally, all instances have been checked to verify that
they do not cast to any invalid types -- most use `u8` or `u32`.

Additionally, the long-deprecated `MemoryRange::from_parts()` call was
removed, since that causes UB without being marked as unsafe.

Signed-off-by: Sean Cross <sean@xobs.io>
2023-09-12 10:03:01 +08:00
nworbnhoj
d4c5ae1447 convert tls::danger to non-public 2023-09-11 13:49:48 +10:00
nworbnhoj
5cacb9c20e TLS tidy-up 2023-09-11 09:37:09 +10:00
nworbnhoj
d57c1143bb TLS doco 2023-09-11 09:35:49 +10:00
nworbnhoj
8ab3aa85be implement tls.probe(target)
moved from tls::cmd to tls::lib
2023-09-11 08:59:08 +10:00
nworbnhoj
a46dad11d2 mtxchat tidy-up 2023-09-09 10:36:37 +10:00
nworbnhoj
66738c0251 mtxchat fix missing write TOKEN_KEY 2023-09-09 10:30:59 +10:00
nworbnhoj
82e5dbe714 mtxchat add progress modal on matrix event import
This progress modal also masks a suspected race condition on Precursor.
    "Guru Mediation" `violated: nonNull::new_unchecked`

Calling ChatOp::PostAdd in quick succession appears to corrupt the pddb record - particularly with more bytes.
2023-09-09 10:30:03 +10:00
nworbnhoj
c50cc73610 mtxchat add navigation help on first login
chat add help navigation modal
2023-09-09 10:24:52 +10:00
nworbnhoj
07ef4d16c2 mtxchat add modal begging for patience 2023-09-09 10:20:24 +10:00
nworbnhoj
7a13439d5c mtxchat replace File & PathBuf with native Pddb 2023-09-09 05:51:21 +10:00
nworbnhoj
fbd49aea21 mtxchat separate pddb::dict for mtxchat.state & mtxchat.dialogue 2023-09-08 19:45:11 +10:00
nworbnhoj
9254163e5a chat implement wifi connect modal 2023-09-08 19:41:59 +10:00
nworbnhoj
e1f1ac427b mtxchat simplify create pddb::dict mtxchat 2023-09-08 18:01:00 +10:00
nworbnhoj
a7d3b34563 Merge branch 'main' into chat 2023-09-08 13:48:45 +10:00
nworbnhoj
3542103510 mtxchat tidy-up 2023-09-08 13:46:52 +10:00
nworbnhoj
9b32333b1e mtxchat README 2023-09-07 17:20:11 +10:00
nworbnhoj
ff68567140 chat UI rawkeys toggle menu_mode & raise app/msg menus 2023-09-07 11:38:21 +10:00
nworbnhoj
ce8c7f51c3 gam forward ALL rawkeys to the current context even when IMEF active
Forwarding of rawkeys to upper layers is important to enable apps to layer additional functionality on top of base.
2023-09-07 11:10:23 +10:00
nworbnhoj
c7c0041922 Chat readme & comments 2023-09-01 05:41:40 +10:00
nworbnhoj
f9c9521c8a fix mtxchat MenuOp::Room 2023-08-30 04:48:05 +10:00
nworbnhoj
2f157d5957 implement ChatOp::Dialogue::Save 2023-08-30 04:46:44 +10:00
Vihaan Jim
41126ec57b Merge branch 'main' of https://github.com/betrusted-io/xous-core 2023-08-29 11:29:39 -04:00
Vihaan Jim
adeaea7757 Add App Loader README 2023-08-28 15:16:12 -04:00
nworbnhoj
7b7a7003f1 implement chat Dialogue navigation with up/down keys 2023-08-28 09:58:57 +10:00
Vihaan Jim
dc295fd9c0 Change `spawn' README 2023-08-26 21:58:16 -04:00
nworbnhoj
6362ff9e4d capture typesetting overflow in ComposedType and pass thru to gam.post_textview() 2023-08-26 03:42:05 +10:00
nworbnhoj
77f25bc416 implement chat icontray 2023-08-23 09:04:42 +10:00
nworbnhoj
197ed63058 chat tidy-up 2023-08-22 16:59:26 +10:00
bunnie
f3a2cba755 map the I/Os so we can see the UART toggle 2023-08-21 18:52:43 +08:00
bunnie
62a424de1b partial progress on udma UART
just a hack-and-slash to get a feel for the peripheral subsystem

currently foiled by instability in loading large binary objects
to the emulated RAM
2023-08-21 03:56:25 +08:00
nworbnhoj
01ea471fd0 implement mtxchat basic chat ui menu 2023-08-15 04:29:07 +10:00
nworbnhoj
4f03a27e79 implement chat app_menu 2023-08-15 04:27:15 +10:00
nworbnhoj
b095462f29 implement mtxchat post() 2023-08-15 04:11:13 +10:00
bunnie
f17ce555f7 sync latest cramium soc defs 2023-08-14 14:22:19 +08:00
bunnie
866330f156 sync release notes 2023-08-14 14:22:05 +08:00
bunnie
a40663bd63 refresh item cache after leaving host readout mode 2023-08-14 14:21:53 +08:00