Pulse/frontend-modern/src/components
rcourtman 1b221cca71 feat: Add configurable allowlist for webhook private IP targets (addresses #673)
Allow homelab users to send webhooks to internal services while maintaining security defaults.

Changes:
- Add webhookAllowedPrivateCIDRs field to SystemSettings (persistent config)
- Implement CIDR parsing and validation in NotificationManager
- Convert ValidateWebhookURL to instance method to access allowlist
- Add UI controls in System Settings for configuring trusted CIDR ranges
- Maintain strict security by default (block all private IPs)
- Keep localhost, link-local, and cloud metadata services blocked regardless of allowlist
- Re-validate on both config save and webhook delivery (DNS rebinding protection)
- Add comprehensive tests for CIDR parsing and IP matching

Backend:
- UpdateAllowedPrivateCIDRs() parses comma-separated CIDRs with validation
- Support for bare IPs (auto-converts to /32 or /128)
- Thread-safe allowlist updates with RWMutex
- Logging when allowlist is updated or used
- Validation errors prevent invalid CIDRs from being saved

Frontend:
- New "Webhook Security" section in System Settings
- Input field with examples and helpful placeholder text
- Real-time unsaved changes tracking
- Loads and saves allowlist via system settings API

Security:
- Default behavior unchanged (all private IPs blocked)
- Explicit opt-in required via configuration
- Localhost (127/8) always blocked
- Link-local (169.254/16) always blocked
- Cloud metadata services always blocked
- DNS resolution checked at both save and send time

Testing:
- Tests for CIDR parsing (valid/invalid inputs)
- Tests for IP allowlist matching
- Tests for bare IP address handling
- Tests for security boundaries (localhost, link-local remain blocked)

Related to #673

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-09 08:31:12 +00:00
..
__tests__ Unify API token reveal workflow 2025-10-15 22:58:31 +00:00
Alerts Fix VM migration issue where custom alert thresholds are lost 2025-11-06 10:27:15 +00:00
Backups Fix empty space below backup chart by matching container and SVG heights 2025-11-06 15:34:20 +00:00
Dashboard Allow layout to expand on wide displays (related to #643) 2025-11-06 21:51:17 +00:00
Docker Fix Docker host row dimming for degraded status 2025-11-06 19:11:17 +00:00
Hosts Fix critical truncation bug preventing data readability on touch devices (related to #643) 2025-11-06 15:00:36 +00:00
icons Refactor: Code cleanup and localStorage consolidation 2025-11-04 21:50:46 +00:00
PMG Fix settings security tab navigation 2025-10-11 23:29:47 +00:00
Proxmox Add replication monitoring plumbing and UI 2025-10-22 16:10:15 +00:00
Replication Add replication monitoring plumbing and UI 2025-10-22 16:10:15 +00:00
Settings feat: Add configurable allowlist for webhook private IP targets (addresses #673) 2025-11-09 08:31:12 +00:00
shared Add AMD GPU temperature monitoring support 2025-11-06 00:19:04 +00:00
Storage Add helpful guidance for empty physical disk list 2025-11-05 19:25:59 +00:00
Toast refactor: unify notifications into global toast 2025-10-22 12:39:01 +00:00
DemoBanner.tsx Fix settings security tab navigation 2025-10-11 23:29:47 +00:00
ErrorBoundary.tsx Refactor: Code cleanup and localStorage consolidation 2025-11-04 21:50:46 +00:00
FirstRunSetup.tsx Fix config backup/restore by enforcing 12-char minimum password (related to #646) 2025-11-07 22:51:55 +00:00
Login.tsx Refactor: Code cleanup and localStorage consolidation 2025-11-04 21:50:46 +00:00
SecurityWarning.tsx Refactor: Code cleanup and localStorage consolidation 2025-11-04 21:50:46 +00:00
TokenRevealDialog.tsx Add reusable API token reveal dialog 2025-10-15 22:45:14 +00:00
UpdateBanner.tsx Refactor: Code cleanup and localStorage consolidation 2025-11-04 21:50:46 +00:00
UpdateConfirmationModal.tsx Fix settings security tab navigation 2025-10-11 23:29:47 +00:00
UpdateProgressModal.tsx Fix CRITICAL bug: UpdateProgressModal polling never started (fixes #671) 2025-11-08 23:26:55 +00:00