Skip to content

feature: password protection & encryption-at-rest#44

Open
konsumer wants to merge 4 commits into
attermann:masterfrom
konsumer:master
Open

feature: password protection & encryption-at-rest#44
konsumer wants to merge 4 commits into
attermann:masterfrom
konsumer:master

Conversation

@konsumer
Copy link
Copy Markdown

@konsumer konsumer commented Apr 7, 2026

I wasn't sure where to put it, so I stuck it in lib/ I am happy to move it somewhere else, or structure it another way, if you are interested.

Essentially, this adds a versioned & offline-brute-force-resistant store for identity, so it's encrypted at rest. This allows a quick device-reset to render it useless to attacker if the device or SD card is compromised. Identity is encrypted, as well as stored messages.

I included a simple example that does register/login (over serial) and tests the identity. I also documented strengths/weakness and suggestions for secure usage and added a script to verify & play with the files on computer.

Related to ratspeak/ratcom#8

@konsumer konsumer changed the title password protection feature: password protection & encryption-at-rest Apr 8, 2026
@konsumer
Copy link
Copy Markdown
Author

konsumer commented Apr 8, 2026

Also, if this doesn't fit in the scope here, no prob. I made it all as easy to use platformio libs, as well:

konsumer and others added 2 commits April 8, 2026 12:16
SD.begin() is only needed for boards with custom SPI wiring (SPI_SCK
defined). microStore::UniversalFileSystem::init() handles standard SD
initialisation internally, so SD.h is now included only under #ifdef SPI_SCK.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@attermann
Copy link
Copy Markdown
Owner

Thanks for the PR @konsumer. Definitely interested in your at-rest encryption feature. Just need to consider where the best home for it would be. Just returning from extended travels and getting back into the groove so I'll get back to you in the coming days.

@konsumer
Copy link
Copy Markdown
Author

konsumer commented May 5, 2026

Yeh, it might not be best here, like maybe it's just an addon for microStore. I want to really go through it and ensure it's the right approach, too. I am trying to balance performance, less decryption calls (like only the private key at boot, then use private key for all else) with enough security that it can't be easily cracked offline.

I worked on several alternative reticulum libs (light ones for arduino, python & js) in the hopes of having a simple reference, but I think in my own planned ESP32 client devices, I want to just use microReticulum, since it has more testing & work around it. We should totally work together!

@konsumer
Copy link
Copy Markdown
Author

konsumer commented May 8, 2026

Another idea I have been thinking about is NVRAM "pepper", which adds a lot of security (would need physical access to device, not just brute-forcing SD) and the concept of development/production mode with locked encrypted secret (so even physical access will not get you in, easily.) I think these measures, with a good password, will really protect things.

I am not sure of the particulars with development/production mode though. I think maybe that just means disabling serial-update via fuses (and requiring OTA updates) which makes updating less convenient, and is still open to DNS OTA attacks and also you can read the flash directly. Maybe someone else has more experience with built-in flash encryption stuff?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants