dan
218b7cdb27
ble: encrypt wifi password
...
BLE "just works" pairing dos not protect against active MITM,
so we need to handle this ourselves. Use nacl/libsodium
crypto_box to encrypt and authenticate the wifi password
this also adds a step to the interaction between client and device:
after writing the password, we now write a "true" to the "connecting"
characteristic to kick off the actual conection attempt.
2026-02-17 12:37:59 +00:00
dan
1a5314d2a3
make keypairs for secure ble
2026-02-15 17:57:07 +00:00
dan
4be5521504
ble: remove unused connection_state attribute
2026-02-15 17:56:18 +00:00
dan
4e0415b62b
notes
2026-02-15 17:13:24 +00:00
dan
c15f26eef6
add crypto_box
2026-02-14 20:35:07 +00:00
dan
48968551cc
add getrandom 0.2.17 with custom source
2026-02-14 20:34:14 +00:00
dan
85aa43b1e9
notes
2026-02-11 19:27:16 +00:00
dan
211cce207a
more link
2026-02-10 18:19:39 +00:00
dan
b29f9459c4
to wit, todo
2026-02-04 19:49:21 +00:00
dan
7fa4a5d36b
PRE-format the todo list
2026-02-04 19:45:50 +00:00
dan
00545725e6
fix syntax
2026-02-04 19:35:33 +00:00
dan
b2c463b1c2
"make install" to flash locally
2026-02-04 19:30:06 +00:00
dan
a892593ea5
sense-check docs and comments
2026-02-04 18:59:46 +00:00
dan
671c2a382c
reset after configuring wifi, and if if doesn't work
2026-02-04 18:42:49 +00:00
dan
d79b32c8bf
delete unused imports
2026-02-04 18:35:20 +00:00
dan
cee50cd4a8
delete dead commented cde
2026-02-04 17:54:25 +00:00
dan
8506980e67
update TODO
2026-02-04 00:48:20 +00:00
dan
601c7391a3
write selected wifi credentials to flash nvs
...
todo
- reboot after writing
- delete bad networks after failing to connect
2026-02-04 00:37:24 +00:00
dan
2cfe436ac9
scan wireless networks & publish over ble
...
does not actually connect yet
2026-02-02 21:19:39 +00:00
dan
938cb4fda0
add licence
2026-02-02 13:07:26 +00:00
dan
dcaa927ab1
don't need ssid and password to do a wifi scan
2026-02-01 22:54:29 +00:00
dan
6c4d64ce0e
demonstrate reading/writing a characteristic
2026-02-01 16:45:53 +00:00
dan
f25a539084
log when current_network_index is changed
2026-02-01 16:43:45 +00:00
dan
a729199926
PoC BLE support
...
It advertises, and it enumerates some characteristics. None of them
are hooked up to anthing yet
2026-02-01 15:27:30 +00:00
dan
13b0868488
esp_radio Controller is shared between wifi, ble
...
in preparation for adding ble, move its creation into main and
pass the object into wifi
2026-02-01 00:17:24 +00:00
dan
9a95889523
update android client to use key
2026-01-31 21:22:43 +00:00
dan
923dbe6fa9
add session registration with signature checking
2026-01-29 19:10:07 +00:00
dan
0d92b907d2
port android/termux client to use eculocate module
2026-01-29 12:27:15 +00:00
dan
341d192dce
add callback method when services change
2026-01-29 12:26:03 +00:00
dan
9bbe366f9e
make eculocate usable as module
...
run code at startup only if main
2026-01-29 12:17:30 +00:00
dan
0c5f205f91
remove unused attribute
2026-01-29 12:15:22 +00:00
dan
93eca2672d
separate start and stop
2026-01-29 12:06:28 +00:00
dan
84f1b93794
remove unused attribute
2026-01-28 17:50:24 +00:00
dan
8251f461ec
I can't see you
2026-01-28 17:43:49 +00:00
dan
632cc8d654
I can't see you
2026-01-28 17:38:28 +00:00
dan
1fe9ddadca
rename property
2026-01-28 17:30:24 +00:00
dan
6cee87af18
print byte count while recording
2026-01-28 17:10:13 +00:00
dan
7e59e40883
cli client program
...
this is presently android.py minus the gui bits, but the plan is to
extract a module that can be used both from linux and from
termux-android
2026-01-28 01:08:44 +00:00
dan
7239e54166
rename client files
2026-01-28 01:06:20 +00:00
dan
e6e7030ba6
fix ota_write_chnk bug
...
somehow hadn't spotted we were not writing the start of the data, oops
2026-01-26 00:25:05 +00:00
dan
fb59198f70
remove read_all, shorten using Result
...
this has made the "can't happen" error messages a bit less helpful
but we will come back to that
2026-01-25 00:44:03 +00:00
dan
0d86c64134
replace read_all with socket.read_exact
2026-01-24 22:20:49 +00:00
dan
ebf60e64ad
clean up crates
...
- remove conflicting versions of embedded-io-async
- delete bluetooth stuff we're not using
2026-01-24 22:18:12 +00:00
dan
04b71489b1
replace join(join) with join3
2026-01-24 00:09:45 +00:00
dan
0937fc8b93
ota flash: print number of blocks
2026-01-23 23:57:45 +00:00
dan
14045825f3
extract module for ota flashing
2026-01-23 23:57:25 +00:00
dan
3a0dbe5c90
sign firmware with chained hashes
...
signing each block individually is slow (well, verifying is slow) and
doesn't protect against a MITM e.g. reordering or dropping
blocks. Instead we use the technique described in "How to Sign Digital
Streams (Gennaro, Rohatgi) where only the _first_ block is
cryptographically signed but each block contains a sha256 hash of its
successor block.
https://users.ece.cmu.edu/~adrian/731-sp04/readings/gr-stream-sig.pdf
2026-01-23 19:38:39 +00:00
dan
2f517e991d
remove tabs
2026-01-23 19:17:19 +00:00
dan
ef1b608ac2
add Cargo.toml to build deps
2026-01-21 23:27:16 +00:00
dan
a3edd49f10
check signature on each block
2026-01-21 21:42:26 +00:00