fix: security hardening, memory leak, file cleanup, and UX improvements#3
Open
salmanrajz wants to merge 2 commits into
Open
fix: security hardening, memory leak, file cleanup, and UX improvements#3salmanrajz wants to merge 2 commits into
salmanrajz wants to merge 2 commits into
Conversation
Security: - Add URL validation (http/https only) on all endpoints - Add format_id sanitization to prevent yt-dlp flag injection - Add job_id format validation (hex, 10 chars) - Add path traversal protection on file serving endpoint - Add non-root user in Dockerfile - Mask internal errors from API responses - Add .env and .vscode/ to .gitignore Stability: - Add threading lock for jobs dict (race condition fix) - Add job TTL auto-purge (1hr) to prevent memory exhaustion - Add MAX_JOBS cap (500) with 503 response when full - Add JSON parse error handling in /api/info - Add explicit debug=False on Flask entry point File management: - Add /api/cleanup endpoint for client-triggered file removal - Frontend calls cleanup 5s after save to free disk space - Pin dependency versions in requirements.txt UX/Frontend: - Fix dlAll() to properly await each download via Promise-based polling - Add ARIA labels on interactive elements - Improve title sanitization (80 char limit, control char removal, no hidden files) DevEx: - Add structured logging throughout backend - Add type hints on all functions - reclip.sh now always runs pip install on venv reuse - reclip.sh adds exit trap for clean shutdown message
nandanosql
referenced
this pull request
in nandanosql/reclip
Apr 7, 2026
- Add POST /api/batch/download endpoint accepting multiple URLs - Add GET /api/batch/status/<batch_id> for batch progress tracking - Use ThreadPoolExecutor with 3 concurrent workers for parallel downloads - Limit batch to 20 URLs per request - Update frontend 'Download All' to use batch API instead of sequential - Fallback to sequential download if batch API fails - Batch status shows done/errors/pending counts Fixes #3
DeBondor
added a commit
to DeBondor/reclip
that referenced
this pull request
Apr 11, 2026
…dening, memory leak, UX) - Pin yt-dlp>=2026.3.17 to fix YouTube SABR 403 errors (fixes averygan#8) - Add --upgrade-deps to reclip.sh venv setup - Add URL validation (http/https only) - Add format_id sanitization against yt-dlp flag injection - Add job_id format validation - Add path traversal protection on file serving - Add non-root user in Dockerfile - Add threading lock for jobs dict (race condition fix) - Add job TTL auto-purge (1hr) + MAX_JOBS cap (500) - Add /api/cleanup endpoint + frontend cleanup call after download - Add structured logging + type hints - Fix dlAll() to await each download via Promise-based polling - Add ARIA labels on interactive elements - Improve title sanitization (80 char limit) - reclip.sh: always run pip install on venv reuse - reclip.sh: add EXIT trap for clean shutdown message
Auzlex
added a commit
to Auzlex/reclip
that referenced
this pull request
Apr 29, 2026
…erygan#24 (security, stability, and progress tracking) - PR averygan#24: Fixed YouTube 403 Forbidden errors by pinning yt-dlp>=2026.3.17. - PR averygan#3: Implemented security hardening (URL validation, format/job ID sanitization, path traversal protection, and non-root Docker user). - PR averygan#12: Added automatic disk management (1-hour job TTL, 500MB directory size cap, and auto-purge). - PR averygan#13: Enhanced download experience with real-time progress tracking, 30-minute timeouts, and UI progress bars. - Backend: Unified app.py with threading locks, structured logging, and configurable cleanup settings via environment variables. - Environment: Updated Dockerfile and reclip.sh for better dependency management and unprivileged execution.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Security:
Stability:
File management:
UX/Frontend:
DevEx: