Skip to content

security: patch command injection, path traversal, and unauthorized access#34

Open
riverwolf67 wants to merge 1 commit into
cytostack:mainfrom
riverwolf67:main
Open

security: patch command injection, path traversal, and unauthorized access#34
riverwolf67 wants to merge 1 commit into
cytostack:mainfrom
riverwolf67:main

Conversation

@riverwolf67
Copy link
Copy Markdown

This PR addresses several security vulnerabilities identified during a codebase audit:

  • Fixed Command Injection (Critical): Replaced execSync string interpolation with execFileSync and array-based arguments in CLI commands.
  • Secured Dashboard (High): Bound dashboard server to 127.0.0.1 and implemented token-based authentication.
  • Fixed Path Traversal (Medium): Added validation in CronEngine to prevent reading files outside the project root.
  • Mitigated DoS (Low): Added a 1MB file size limit to the file watcher broadcast.
  • Added Security Test Harness: Introduced an automated test suite using the native Node.js test runner.

See summary.md in the PR for details.

…ccess

- Fix critical command injection in CLI by using execFileSync
- Bind dashboard to localhost and add token-based authentication
- Prevent path traversal in CronEngine via path resolution validation
- Mitigate DoS in file watcher with 1MB broadcast limit
- Add security test harness using node:test
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