Add MQTT enrollment demo with Gitea deploy pipeline
Test and deploy enrollment demo / test (push) Successful in 7s
Test and deploy enrollment demo / deploy (push) Successful in 1m12s

Go backend plus C (libsodium) and C++ (OpenSSL) simulated boards enroll
through a Mosquitto 2.1 broker with Dynamic Security using X25519/HKDF/
Ed25519; a web view shows the run live. The Gitea workflow validates and
builds the images, redeploys the stack on the server with the viewer on
port 8099 and fails unless both boards pass all checks.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-24 21:25:14 +03:30
co-authored by Claude Sonnet 5.5
commit bf40b92c52
109 changed files with 15357 additions and 0 deletions
+18
View File
@@ -0,0 +1,18 @@
#!/usr/bin/env bash
# Builds the libsodium C program and diffs its output against the Go program (run ./run.sh first).
# With real libsodium headers installed, set LIBSODIUM_CFLAGS/LIBSODIUM_LIBS (or drop the shim).
# Default: the machine's libsodium 1.0.20 shared library (no headers) plus the local shim header.
set -euo pipefail
cd "$(dirname "$0")"
mkdir -p out
SO="${LIBSODIUM_SO:-/nix/store/gaaqqkh7pvr85vh2vdclw8z2m4w1lq8q-libsodium-1.0.20/lib/libsodium.so}"
if [ -n "${LIBSODIUM_LIBS:-}" ]; then
gcc -std=c11 -Wall -Wextra -O2 ${LIBSODIUM_CFLAGS:-} -o out/spike-sodium c-libsodium/main.c $LIBSODIUM_LIBS
else
gcc -std=c11 -Wall -Wextra -O2 -Ic-libsodium/shim -o out/spike-sodium c-libsodium/main.c \
"$SO" -Wl,-rpath,"$(dirname "$SO")"
fi
./out/spike-sodium > out/sodium.txt
diff out/go.txt out/sodium.txt && echo "go == c (libsodium)"