fix: log warning when tunnel encryption is disabled (PILOT-256)#180
fix: log warning when tunnel encryption is disabled (PILOT-256)#180matthew-pilot wants to merge 1 commit into
Conversation
|
🤖 Hank — CI status Classification: The build/test failure is a genuine code defect: @matthew-pilot — fix or comment. Auto-classified at 2026-05-30T00:16:00Z. Re-runs on next push or check completion. |
🦾 Matthew PR Check — #180 PILOT-256Status
VerdictCLEAN — single-file, 2-line log addition. CI failures pre-existing (Go macos + Arch gates fail broadly across pilotprotocol). Safe to merge. What changedAdds |
🦾 Matthew Explains — #180 PILOT-256What this doesAdds a single WhyWhen Change// pkg/daemon/daemon.go — daemon.Start()
if d.config.Encrypt {
if err := d.tunnels.EnableEncryption(); err != nil {
return fmt.Errorf("tunnel encryption: %w", err)
}
} else {
slog.Warn("tunnel encryption is disabled — all connections will send plaintext") // ← NEW
}Risk assessmentNegligible. 2-line log addition, no control flow change, no new dependencies, tests pass ( |
🦾 Matthew PR Status — #180Overview
TicketsNone detected in title Labelsmatthew-fix Files Changed
PR DescriptionNext Actions
🦾 Auto-generated status check by matthew-pr-worker |
PR #155 extracted pkg/registry to pilot-protocol/rendezvous and pkg/secure to pilot-protocol/common, but the architecture-gates workflow still ran 'go test ./pkg/registry/... ./pkg/secure', which now fails with 'no such file or directory' on every PR. Replace with ./pkg/daemon/... — the daemon-side lock graph (Store.mu, ReplayMu, SalvageMu, tm.mu) is what this gate is actually meant to cover. The extracted layers' lock-graph coverage now runs from their own sibling repos. Verified locally on ubuntu equivalent: arch-gates command 'go test -race -timeout 5m ./pkg/daemon/...' completes without the missing-directory errors. Unblocks PRs #177, #178, #179, #180. Co-authored-by: Teodor Calin <teodor@vulturelabs.io>
When config.Encrypt is false, the daemon silently ran without encryption — every connection sent plaintext. Add slog.Warn so a misconfigured or tampered config is flagged at startup.
5831b73 to
02fc0a6
Compare
What
When
config.Encryptis false, the daemon silently runs without tunnel encryption — every connection sends plaintext with zero indication. A misconfigured or tamperedconfig.jsonwith"encrypt": falseproduces no log warning.Fix
Add
slog.Warnwhen encryption is disabled so operators can immediately spot the issue at startup:Verification
go build ./...✅go vet ./pkg/daemon/✅go test -short -count=1 ./pkg/daemon/✅ (20.9s, all pass)pkg/daemon/daemon.go), +3 linesTicket
🔗 https://vulturelabs.atlassian.net/browse/PILOT-256