Skip to content

Fix section-aware config parsing, document security flags#3

Merged
Lightheartdevs merged 2 commits intomainfrom
fix-config-parsing-and-docs
Feb 17, 2026
Merged

Fix section-aware config parsing, document security flags#3
Lightheartdevs merged 2 commits intomainfrom
fix-config-parsing-and-docs

Conversation

@Lightheartdevs
Copy link
Copy Markdown
Collaborator

Summary

  • Critical fix: parse_yaml() / Parse-Yaml now scopes key lookups to YAML sections using "section.key" format (e.g., "token_spy.enabled" instead of "enabled"). Previously, duplicate keys like enabled, port, host across session_cleanup / tool_proxy / token_spy sections would silently return the wrong value.
  • Security docs: Added Gateway Config section to README explaining dangerouslyDisableDeviceAuth and allowInsecureAuth.
  • Windows timer fix: Added explicit RepetitionDuration to cleanup task trigger for reliability.

Test plan

  • Verify bash parse_yaml returns correct per-section values
  • Verify PowerShell Parse-Yaml returns correct per-section values
  • Confirm top-level keys like system_user still work without section prefix

LightHeart and others added 2 commits February 16, 2026 21:26
…ded .gitignore

Prevents agents and contributors from accidentally committing secrets:
- .pre-commit-config.yaml: gitleaks + detect-private-key hooks (local)
- .github/workflows/secret-scan.yml: gitleaks action on PRs and pushes (CI)
- .gitignore: global patterns for .env, keys, certs, credentials, keystores

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Critical bug fix: parse_yaml()/Parse-Yaml matched the first occurrence
of a key name globally, so duplicate keys like 'enabled', 'port', 'host'
across session_cleanup/tool_proxy/token_spy sections would silently
return the wrong section's value. Now uses "section.key" format
(e.g., "token_spy.enabled") to scope lookups within YAML sections.

Also:
- Document dangerouslyDisableDeviceAuth and allowInsecureAuth in README
- Add RepetitionDuration to Windows cleanup timer for reliability

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@Lightheartdevs Lightheartdevs merged commit 0d9bd1e into main Feb 17, 2026
1 check failed
igorls referenced this pull request in igorls/DreamServer Mar 9, 2026
Shell Scripts:
- dream-restore.sh: Replace hardcoded config list with dynamic glob for
  compose overlays (.base.yml, .nvidia.yml, etc.) (Light-Heart-Labs#4)
- dream-update.sh: Use resolve-compose-stack.sh for container restart
  instead of hardcoded docker-compose.yml (Light-Heart-Labs#7)
- dream-update.sh: Enable dotglob in rollback to restore hidden files
  like .env and .version (Light-Heart-Labs#6)
- dream-backup.sh: Include .tar.gz archives in retention/list queries
  to prevent infinite disk accumulation (Light-Heart-Labs#9)
- dream-backup.sh: Dynamic glob for config backup (compose overlays)

Token Spy:
- compose.yaml: Add persistent volume mount for data/ directory to
  prevent SQLite data loss on container restart (#2)
- main.py: Offload blocking SSH subprocess to thread pool via
  asyncio.to_thread() to prevent event loop deadlock (#3)
- main.py: Add finally blocks in streaming generators to guarantee
  billing metrics are logged on asyncio.CancelledError (Light-Heart-Labs#8)
- db_postgres.py: Add conn.rollback() on failed SQL to prevent
  connection pool poisoning (Light-Heart-Labs#10)

Installer:
- detection.sh: Run systemd auto-resume service as root instead of
  $USER to prevent sudo password hang and permission errors (Light-Heart-Labs#11)
igorls referenced this pull request in igorls/DreamServer Mar 10, 2026
… audit

CRITICAL:
- #1: Command injection via SUDO_USER — switched execSync to
  execFileSync in getUserHome() to bypass shell interpolation
- #2: Symlink attack in /tmp — selfUpdate() now uses mkdtempSync
  with 0700 perms instead of hardcoded /tmp paths

HIGH:
- #3: SHA256 verification failure — download binary with artifact
  name so sha256sum --check finds the correct file
- Light-Heart-Labs#4: Broken rollback — verify new binary via exitCode check,
  not dead catch block (throwOnError: false skips catch)
- Light-Heart-Labs#5: Data loss in uninstall — docker compose down -v now
  conditional on !keepData
- Light-Heart-Labs#6: rm -rf path safety — refuse system directories (/, /home,
  /root, /usr, etc.) with structural depth check

MEDIUM:
- Light-Heart-Labs#7: Model download failure halts install (throw instead of
  silent return) — prevents llama-server crash-loop
- Light-Heart-Labs#8: Tier change now applies CTX_SIZE even when model name
  unchanged (Tier 1->2 both use qwen3-8b but differ in context)

Tests: updated model.test.ts to expect throw on download failure
All 138 tests passing
Lightheartdevs added a commit that referenced this pull request Mar 30, 2026
#3

Special section: reworded as continuing ally, not past tense. "Drives"
not "drove", "keeps bringing" not "brought".

Resistance list: restored as #3 contributor (after Yasin and Youness)
with full contribution details. He belongs in both places.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Lightheartdevs added a commit that referenced this pull request Mar 30, 2026
#3

Special section: reworded as continuing ally, not past tense.
Resistance list: restored as #3 contributor with full details.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Lightheartdevs added a commit that referenced this pull request Mar 30, 2026
#3

Special section: reworded as continuing ally, not past tense.
Resistance list: restored as #3 contributor with full details.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Lightheartdevs added a commit that referenced this pull request Mar 30, 2026
docs: fix Tony's Wall of Heroes — present tense + Resistance #3
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.

1 participant