Skip to content

Runtime configuration auditing#105

Open
gloskull wants to merge 2 commits into
Utility-Protocol:mainfrom
gloskull:Runtime-Configuration-Auditing
Open

Runtime configuration auditing#105
gloskull wants to merge 2 commits into
Utility-Protocol:mainfrom
gloskull:Runtime-Configuration-Auditing

Conversation

@gloskull

Copy link
Copy Markdown
Contributor

Motivation
Provide a deterministic, low-latency runtime configuration auditing layer to detect drift between deployed baselines and live service configuration for system-wide observability and safer rollouts.
Ship an initial implementation for the meter simulator to define the pattern for other services and integrate with monitoring, canaries, and blue-green deploys.
Description
Add meter-simulator/src/runtime-config-auditor.js implementing canonicalization, stableStringify, hashConfig, secret redaction, flattenConfig, diffValues, and a RuntimeConfigAuditor class with createSnapshot, setBaseline, and audit methods.
Add unit tests meter-simulator/tests/runtime-config-auditor.test.js covering deterministic hashing, redaction, path-level drift detection, no-drift behavior, and additions/removals detection.
Add documentation docs/RUNTIME_CONFIG_AUDIT.md describing architecture, security model (redaction rules), runbook, monitoring expectations, and rollout guidance for drift-based gating.
Testing
Ran unit tests for the new auditor with npm test -- runtime-config-auditor.test.js --runInBand, which passed (4 tests).
Ran the full simulator test suite with npm test -- --runInBand, which failed due to pre-existing meter-device test issues (unrelated to this change) such as bad secret key size, peak-hour expectation mismatches, and message-length assertions.
Attempted cargo test -p utility_contracts for broader integration, which did not complete due to pre-existing Rust compile errors (e.g. duplicate MIGRATION_INSTRUCTION_BUDGET, overlong symbol_short! usage, and other compile-time issues) unrelated to the meter-simulator additions.
Closes #86

gloskull added 2 commits July 17, 2026 18:44
…auditing

Add runtime configuration drift auditing for meter-simulator
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.

Runtime Configuration Auditing and Drift Detection

1 participant