Commit graph

241 commits

Author SHA1 Message Date
bunnie
ff30131f43 absorb more fixes into the kernel 2022-10-13 04:08:56 +08:00
bunnie
3503965f98 bump versions to absorb xous-rs changes 2022-10-13 03:41:16 +08:00
bunnie
02b80425f5 bump xous-rs to absorb change in language specification 2022-10-10 03:07:44 +08:00
bunnie
9732ecdc18 add v0.9.10 to restore URL list 2022-10-09 23:37:48 +08:00
bunnie
01b68cbdc9 fix development roll-out process for picking a restore kernel 2022-10-09 14:18:57 +08:00
bunnie
99c6e005ad fix hosted mode 2022-10-09 02:46:24 +08:00
bunnie
6230c922ac fix backup/restore scripts 2022-10-09 02:36:48 +08:00
bunnie
8ac80f8c42 update tools to work with checksums (partial update) 2022-10-09 01:12:03 +08:00
bunnie
c33dee152d fix backup opcode setting 2022-10-08 22:20:50 +08:00
bunnie
c471ca0fbb fix overly restrictive version match on backup version 2022-10-08 15:29:37 +08:00
bunnie
a0791ff092 back out patch of the opcode change -- the backup script did that in error 2022-10-08 02:40:55 +08:00
bunnie
89d050891b fix incorrect opcode setting on backup 2022-10-08 02:40:07 +08:00
bunnie
44d3c19733 fix hash check computation and op offset 2022-10-08 02:26:00 +08:00
bunnie
42052fdcc5 fix padding on hash check in backup tools 2022-10-08 01:53:28 +08:00
bunnie
a416069002 add hash protection on the metadata header
stage is set for hash protection on the PDDB data itself.
that comes next.
2022-10-08 01:22:14 +08:00
bunnie
0f9195f305 add some sanity checks on the backup header
this tries to catch the cases that:
  - user tried to run the backup without first running "prepare backup..."
  - the USB connection is a little flakey and returning bum data

We can only inspect the plaintext portions of the header, which contains
things like protocol version numbers, time stamps, and language codes.

We use the timestamp validation heavily because it's the only field that
isn't almost always going to be a 0 or 1 when correct, which are highly
likely to be reported anyways if there's a problem with the USB link.

This does assume the user sets the time correctly on the device
doing the backup, and on the Precursor itself.
2022-10-06 00:53:52 +08:00
bunnie
3bca9de2a0 bump version numbers for xous-kernel patch
this fixes tests in CI
2022-10-05 23:51:35 +08:00
bunnie
969f93b001 cross-repo update versions from xous-rs bump 2022-10-05 18:32:44 +08:00
bunnie
776a47f4bc missed a file 2022-10-02 02:21:06 +08:00
bunnie
15bcb6328f fixup other refs 2022-09-27 03:09:41 +08:00
bunnie
3579dfdd17 update xous-ipc and xous versions 2022-09-26 16:07:35 +08:00
bunnie
796256cfb0 make usb_update.py appear only once in the tree 2022-09-19 12:44:55 +08:00
bunnie
5461a70be1 add some generated data for later review 2022-09-16 01:52:06 +08:00
bunnie
46a2d8609f add perflib modules
this library can be re-used across multiple scenarios that require
performance profiling
2022-09-16 01:48:59 +08:00
bunnie
3a893213ff update the generated images to the latest data 2022-09-16 01:47:30 +08:00
bunnie
e12f651ac4 update analysis framework to use the binary files output by the latest changes 2022-09-16 01:47:02 +08:00
bunnie
3e79e3e430 add ability to read out data based on a list of virtual sectors
This adds the `--dump` command, which requires a file that is
a copy/paste of a generated virtual to physical table. An example
of this log would look like this:

```
INFO:shellchat::cmds::net_cmd: V|P 6000d000 40799000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 6000e000 4079a000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 6000f000 4079b000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 60010000 4079c000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 60011000 4079d000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 60012000 4079e000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 60013000 4079f000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 60014000 407a0000 (services\shellchat\src\cmds\net_cmd.rs:770)
INFO:shellchat::cmds::net_cmd: V|P 60015000 407a1000 (services\shellchat\src\cmds\net_cmd.rs:770)
```

and so forth. The script can parse this raw log to create the necessary
page table mappings to read a large region of virtual memory and save
it as a contiguous chunk in a file.
2022-09-16 01:39:49 +08:00
bunnie
57291a47f2 add some sample outputs from the analysis scripts 2022-09-11 21:16:45 +08:00
bunnie
088648409e add constant time analysis script 2022-09-11 19:13:38 +08:00
bunnie
2ee0d4dfce remind myself how to update the precursorupdater
the latest docs don't work for us, so, document our method here.
Just can't figure out the .toml method of describing the project...
2022-09-09 15:39:52 +08:00
bunnie
4b72492c3e fix bug #216 2022-09-09 15:07:31 +08:00
bunnie
ca3cc711a4 Re-add usb_update.py, but with modified help to guide users
It's a bit confusing to run the wrong tool but hopefully there
are ample help messages sprinkled in this to guide the average
user to the right location.
2022-08-16 13:57:36 +08:00
bunnie
5e455b60eb add debug to backalyzer to dump encrypted private key 2022-08-12 20:10:19 +08:00
bunnie
58a8264080 fix some bugs in printing errored-out sectors
also print the sector data that errors out -- might be a bit
much at the moment but it's very helpful for immmediately
visualizing a loss-of-power event related write corruption
2022-08-06 16:00:15 +08:00
bunnie
3a5e385b9a add arg to specify file (optionally) in backup 2022-07-29 00:24:40 +08:00
bunnie
a68eb7cc73 add missing files for backalyzer; add PTE conflict resolution 2022-07-28 04:47:02 +08:00
bunnie
e2f7a75f87 improve help message 2022-07-26 03:43:31 +08:00
bunnie
6266101727 backalyzer now works with PDDB in hosted mode.
Specify file as `-f pddb-images/hosted.bin` and use `--hosted`
2022-07-26 03:42:11 +08:00
bunnie
c889f5576f cleanup backalyzer. i think it's basically ready to go now 2022-07-26 03:09:09 +08:00
bunnie
22a85ba022 working draft of backalyzer 2022-07-26 02:53:19 +08:00
bunnie
ba7532a4fe fix backup length
we were accidentally also backing up the WF200 firmware as well,
chop that off so that the analysis scripts & restore works correctly.
2022-07-26 02:52:40 +08:00
bunnie
ef29e6e504 re-org the python pddb analysis scripts
allow for elements of pddbdbg.py to be shared with the backalyzer.py
2022-07-26 00:06:16 +08:00
bunnie
494ec7c2b3 improve the basis name validator - ':' is an illegal character in a basis name. 2022-07-26 00:05:45 +08:00
bunnie
a0a51cab5c emphasize that you must reboot by using the paperclip 2022-07-23 16:23:05 +08:00
bunnie
97b13e7df3 move the OG signing tool to legacy status 2022-07-23 16:08:47 +08:00
bunnie
b4a784391d clean up the tools directory 2022-07-23 16:07:33 +08:00
bunnie
c43aa7f77e remove egg and dist from the index as it is dynamically generated 2022-07-23 00:11:32 +08:00
bunnie
a43e0640f9 i'm not sure if these typically end up in repos, but they're there... 2022-07-22 22:29:32 +08:00
bunnie
5bce709d3c some cosmetic improvements and release notes acknowledgements 2022-07-22 22:28:46 +08:00
Jeremy O'Brien
b47fccde6a precursorupdater python package improvements
move precursorupdater's main into its own namespace and handle both
running from the repo directly and from pip
2022-07-22 09:53:04 -04:00