Open
Conversation
Phase 1 — Critical: - arlo-viewer: fail-fast if AUTH_PASSWORD/AUTH_SECRET/THUMBNAIL_SECRET/TLS vars unset - arlo-viewer: replace SHA256 swizzle with PBKDF2 (100k iterations) for session tokens - arlo-viewer: switch HTTP server to HTTPS (TLS cert path from env) - arlo-viewer: cookie hardening — SameSite=Strict, Secure flag, 30-day Max-Age - arlo-viewer: safeFilePath() using path.resolve() prefix check on all file endpoints - arlo-viewer: rate limit /login to 10 attempts per 15 minutes (express-rate-limit) - api.py: bind Flask to 127.0.0.1:5000 only (fix lambda bug in get_thread too) - api.py: serial number format validation in validate_camera_request() - api.py: snapshot endpoint — identifier regex, realpath path check, 5MB size limit - api.py: require_bool() helper applied to userstreamactive endpoint - api.py: fix bare except -> except Exception - install.sh: generate AUTH_SECRET, THUMBNAIL_SECRET, VIEWER_PASSWORD at install time - install.sh: write /etc/arlo/viewer.env (mode 640, root:user) - install.sh: generate self-signed TLS cert in /etc/arlo/tls/ - install.sh: write ThumbnailSecret into arlo-cam-api config.yaml - install.sh: add EnvironmentFile to installed arlo-viewer.service - install.sh: print generated password at completion Phase 2 — High: - arlo-viewer: HMAC-SHA256 token required on /api/thumbnail/:filename - arlo-viewer: /api/recordings includes pre-signed thumbnailUrl per entry - webhook_manager: append ?token=<hmac> to ntfy Attach thumbnail URL Phase 3 — Medium: - arlo-viewer.service: add EnvironmentFile=/etc/arlo/viewer.env - config.yaml.example: document ThumbnailSecret field - package.json: add express-rate-limit dependency Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…session
1. Sanitize verbose exception messages (api.py)
- stream_start/stop now log internally and return generic error strings
- Internal IPs, paths, and exception details no longer leak to clients
2. Security headers (server.js)
- Add X-Content-Type-Options: nosniff
- Add X-Frame-Options: DENY
- Add Referrer-Policy: no-referrer
3. XSS fix in recording gallery (index.html)
- Add escapeHtml() helper
- All user-controlled values (serial, friendlyName, filename, camera, timestamp)
now escaped in HTML context
- onclick handlers use data attributes instead of string interpolation
to prevent JS injection via crafted camera names
4. Friendly name length validation (api.py)
- Reject names over 64 characters or non-string values
5. Socket timeout (arlo/socket.py)
- ArloSocket now sets 30s timeout on all sockets at construction
- Prevents hung connection threads when cameras stop sending mid-message
6. Absolute database path (server.py, arlo/camera.py, api/api.py, helpers/connectivity_checker.py)
- All sqlite3.connect() calls now use DB_PATH computed from __file__
- No longer dependent on process working directory
7. Reduce session cookie lifetime from 30 days to 24 hours (server.js)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.
Asked Claude to recommend some fixes to cover security issues, and it proposed a range of critical and low priority fixes. Haven't tested them yet but hope to test soon.