Commit Graph

45 Commits

Author SHA1 Message Date
bd7dda0c6f feat(secubox): complete meta-script generator Tasks 14-17
Task 14: Arch Profiles
- Add profiles/arch/arm64.yaml and profiles/arch/amd64.yaml
- Add ResolveWithArch() to merger for base → arch → tier chain
- Add tests for arch profile resolution

Task 15: Package secubox.yaml for All Packages
- Add scripts/generate-secubox-yaml.py generator script
- Generate 131 debian/secubox.yaml files with:
  - Category detection (security, network, system, etc.)
  - Tier assignment (all, lite, standard, pro)
  - API socket and UI path detection

Task 16: APT Repository Setup
- Add apt/conf/ reprepro configuration (multi-arch arm64/amd64)
- Add apt/hooks/lintian-check pre-publish validation
- Add scripts/apt-publish.sh and scripts/apt-sync.sh
- Add apt/README.md documentation

Task 17: CI Integration
- Add .github/workflows/build-secubox-cli.yml
- Build for linux-amd64 and linux-arm64
- Version injection via ldflags
- GitHub releases on tag push

Code Quality Fixes (Tasks 10-13):
- Add atomic writes for OTA boot control files (0600 perms)
- Fix NVME device extraction (nvme0n1p2 → nvme0n1)
- Add scanner.Err() checks in hardware detection
- Fix URL injection validation in fetch command
- Add proper cleanup on checksum failures

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-11 05:32:29 +02:00
128ee01209 fix(waf): Optimize mitmproxy WAF and fix dead container routes
WAF Optimizations:
- Skip WAF checks for static assets (.js, .css, .png, etc.)
- Skip WAF checks for /health, /status, /system_health
- Skip WAF checks for trusted hosts (git, admin)
- Fixed MultiDictView.to_dict() → dict() AttributeError
- CPU: 90%+ constant → 0% idle, 25-90% under load

Route Sync:
- Auto-fix routes pointing to dead containers (10.100.0.10-50)
- Dead routes redirect to webui (9080) instead of timeout
- Fixed bash arithmetic for set -e compatibility

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-09 13:27:18 +02:00
a455b1735e feat: Add route sync, enhanced export, and session management
- scripts/sync-mitmproxy-routes.sh: Auto-sync HAProxy vhosts to mitmproxy
  - Runs via systemd timer every 5 minutes
  - Fixed bash arithmetic for set -e compatibility

- secubox-metablogizer: Enhanced export ZIP package
  - Includes nginx.conf, haproxy.cfg, certificates
  - Complete README with republishing instructions
  - Site health check endpoint

- secubox-users: Added REVOKE ALL sessions panic button
  - Emergency endpoint to revoke all active sessions
  - Double confirmation UI for safety

- secubox-publish: Added health status columns
  - HTTP/HTTPS/WAF status with emoji indicators
  - Aggregated health LEDs bar

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-09 13:11:34 +02:00
e2989322f4 feat(api): Add /health endpoint to 53 modules
Auto-generated health check endpoints for sidebar status:
- Returns {status: "ok", module: "name"}
- Public endpoint (no auth required)
- Used by sidebar.js for LED status display

Added via scripts/add-health-endpoints.py

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-09 10:40:05 +02:00
eef430e123 feat(docs): Add screenshot capture system and multilingual wiki generator
- scripts/capture-screenshots.py: Auto-discovers 117 modules from packages/
  - Playwright-based capture with JWT authentication
  - 30-second delay per page for cache refresh
  - Thumbnail generation (400x225)
  - JSON manifest output

- scripts/generate-docs.py: Extended to 105 modules
  - Multilingual descriptions (EN, FR, DE, ZH)
  - --include-screenshots flag for wiki integration
  - Category index pages (CATEGORIES-XX.md)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-09 10:09:21 +02:00
919d030a58 feat(ui): Add dice icons, scribe trace, and LED pulse improvements
- Sidebar: Replace LED dots with dice icons (⚀-⚅) based on metric values
- Sidebar: Dice update dynamically with CPU/mem/disk/load/temp/net
- SOC: Add scribe trace histogram for firewall packet stats
- SOC: Remove category tag listings (keep donut metrics)
- SOC: Fix API paths for hub endpoints
- WAF: Fix JavaScript syntax errors (orphan returns, extra braces)
- WAF: Fix getSiteEmoji function structure
- HealthBump: Update LED pulse patterns (1/2/4 flashes per tier)
- HealthBump: Pulse from bright to dim (not dark to color)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-08 22:33:23 +02:00
81ec2ede51 feat(ui): Sidebar v2.30.0 with hardware LED health bumper integration
- Add 3 vertical RGB LEDs in sidebar header (next to SECUBOX logo)
- LEDs mirror physical MOCHAbin hardware LEDs (HW/SVC/SEC layers)
- Add double-buffer pattern for LED state management
- Add multi-layer histogram tooltip (current/average/max values)
- Add 🚀 emoji to version display
- Move Smart Strip to top menu bar with hover tooltips
- Add persistent sparkline history cache (localStorage, 60 samples, 1h TTL)
- Fix SOC and Certs health endpoints (nginx routes, service restart)
- Hardware LED health bumper script with I2C double-buffering
- CSS: vertical LED strip, histogram bars, header layout fixes

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-08 17:56:18 +02:00
1e1dd7cf89 feat(led-heartbeat): Add bash heartbeat script and diagnostic tool (ref #39)
- Add secubox-led-heartbeat-bash: simple sysfs-based heartbeat with I2C timing delays
- Add scripts/diag-leds.sh: comprehensive LED diagnostic script
- Working heartbeat: 150ms ON, 150ms OFF, 150ms ON, 700ms pause
- Fixes I2C EIO errors by using appropriate delays between writes

Tested on MOCHAbin with IS31FL3199 LED controller.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-07 07:13:59 +02:00
3146e1665d fix(infra): Fix vhost-matrix-sync stderr logging for clean JSON output
- Fix log messages going to stdout which corrupted JSON capture
- Redirect extraction and generation logs to stderr
- Successfully syncs 94 vhosts to mitmproxy routes and health prober
- Tested on server with full HAProxy config

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-06 17:32:27 +02:00
3f0b549a13 feat(infra): Add vhost-matrix-sync.sh + fix Eye Remote metrics endpoint
VHost Matrix Sync (scripts/vhost-matrix-sync.sh):
- Extracts vhost→backend mappings from HAProxy config
- Syncs to mitmproxy routes.json (using 10.100.0.1 for LXC bridge)
- Syncs to health prober vhost-matrix.json
- Commands: sync, status, reload

Eye Remote Round UI fix:
- Changed METRICS_ENDPOINT from /api/v1/system/metrics
  to /api/v1/eye-remote/metrics/public
- Pi Zero will now fetch MOCHAbin host metrics, not local metrics

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-06 17:14:48 +02:00
f42ff0fd9c fix(health): VHost health prober placeholder categorization + Eye Remote metrics
- VHost Health: Add "placeholder" status category to prober
  - Placeholders no longer counted as "down"
  - Health % only reflects real services
  - Dashboard shows  indicator for placeholders

- Eye Remote API: Enhanced metrics exposure
  - Proper CPU calculation (not load average)
  - Memory free/total in MB
  - Disk free/total in GB
  - Active connections and sessions
  - Services running count (86 sockets)
  - VHost health summary

- HAProxy workflow script (scripts/haproxy-workflow.sh)
  - rehealth: Reload HAProxy, invalidate caches, restart probers
  - waf-sync: Sync vhost→backend routes to mitmproxy
  - certs: Check certificate status for all vhosts

- mitmproxy routing: Fixed 127.0.0.1 → 10.100.0.1 (LXC bridge IP)
  to prevent routing loop causing CPU spike

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-05-06 16:44:49 +02:00
6027178c53 fix(deploy): Remove --delete from www rsync to prevent module conflicts
Multiple packages share /usr/share/secubox/www/ - using --delete was
wiping out other modules' files when deploying a single package.
2026-05-02 18:13:16 +02:00
9a5323655c feat(bench): Add performance benchmark suite for ARM64 optimization
Add comprehensive profiling and benchmarking tools for SecuBox service
optimization on constrained ARM64 devices (ESPRESSObin 1GB, MOCHAbin 8GB).

Scripts included:
- api-latency.py: HTTP endpoint latency measurement (P50/P95/P99)
- memory-baseline.sh: Per-service memory tracking (RSS/PSS/USS)
- startup-time.sh: Service cold-start measurement via systemd
- cpu-profile.sh: Flame graph generation with py-spy
- locustfile.py: Load test scenarios for Locust framework

Performance targets:
- ESPRESSObin: P50 <100ms, P99 <500ms, RSS <50MB/service
- MOCHAbin: P50 <50ms, P99 <200ms, RSS <100MB/service

Part of OpenWrt → DEB migration performance optimization work.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-30 09:12:00 +02:00
cf81e8c9be feat(migration): Add --exclude-services option to export script
Added service exclusion capability to migration-export.sh:
- New --exclude-services parameter accepts comma-separated list
- Skips specified /srv/* directories during export
- Useful for excluding large services (nextcloud, peertube, gitea, lxc)

Example: --exclude-services "nextcloud,peertube,gitea,lxc,photoprism"

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-29 15:34:35 +02:00
6edd343019 feat(migration): Extend migration tools v2.1.0 with 19 modules
Add comprehensive data migration covering all SecuBox services:

Export modules (migration-export.sh):
- dns: BIND zones, Vortex RPZ blocklists, Unbound, AdGuard, Pi-hole
- databases: SQLite, MySQL/MariaDB, PostgreSQL, Redis dumps
- scripts: Custom scripts, systemd units, rc.local, cron jobs
- services: All /srv/* directories including:
  - Streamlit instances
  - Metablogizer/Metabolizer apps
  - Gitea/Git repositories with full history
  - Docker compose configurations
  - LXC container configs
  - mitmproxy, config-vault, saas-relay

Import modules (migration-import.sh):
- Corresponding restore functions for all new modules
- Service detection and systemd integration
- Database restore with owner/permission handling

Enhanced HAProxy export:
- conf.d modular architecture
- Certificate management
- Lua scripts and maps
- mitmproxy route integration

Total modules: 19 (network, firewall, wireguard, crowdsec, dhcp,
haproxy, nginx, certs, content, vhosts, users, state, git, media,
mail, accounts, dns, databases, scripts, services)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-29 14:17:30 +02:00
a8b80ff9c4 feat(migration): Extend migration tools v2.0.0 with full data export
Add comprehensive data migration modules:
- git: Git repos, Gitea/Gogs/GitLab data
- media: Videos, PeerTube, Jellyfin, Nextcloud files
- mail: Maildir, Postfix/Dovecot configs, DKIM keys
- accounts: Home dirs, passwd/shadow, sudo, crontabs

Tested on ESPRESSObin with 77 CrowdSec scenarios, vhosts,
web content, and user accounts successfully migrated.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-29 14:08:28 +02:00
6b3a9eb32d feat(migration): Add OpenWrt → SecuBox-DEB migration tools
Migration Data Saver v1.0.0:
- migration-export.sh: SSH export from SecuBox-OpenWrt
- migration-import.sh: Import with transformations + rollback
- migration-transform.py: UCI → TOML/netplan/nftables converter

Supported modules: network, firewall, wireguard, crowdsec, dhcp,
haproxy, nginx, certs, content, vhosts, users, state

Features:
- UCIParser for OpenWrt config format
- NetworkTransformer: UCI → netplan YAML
- FirewallTransformer: UCI → nftables rules
- DHCPTransformer: UCI → dnsmasq.conf
- AES-256 archive encryption
- SHA256 checksums
- Pre-import rollback snapshots (4R pattern)

Also adds plan for Eye Remote Recovery Boot System (kwboot, mvebu64boot,
Tow-Boot UEFI integration for MOCHAbin/ESPRESSObin recovery).

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-29 12:45:47 +02:00
33304e7b6f feat(build): Add kiosk mode + VirtualBox setup + Profile Generator architecture
VM-x64 Build Improvements:
- Enable kiosk mode by default with GRUB menu entries
- Increase image size to 8GB (5.5GB root) for full package set
- Add proper EFI boot configuration with 3 boot modes
- Pre-generate SSL certificates during build
- Add TTY2 autologin for emergency console access

VirtualBox Support:
- Add scripts/vbox-setup.sh for automated VM setup
- Add wiki/VirtualBox-Setup.md with comprehensive guide
- Support bridged, NAT, and host-only network modes
- Auto-detect network adapter for bridged mode

Architecture Documentation:
- Add docs/architecture/profile-generator.md (v0.2)
- Define tier × board × flavors resolution model
- Document 3 CLI tools: secubox-gen, secubox-build, secubox-fetch
- Add Phase 12-14 roadmap alignment for Ulule Campaign 1

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-29 09:16:36 +02:00
372c6e32d6 feat(scripts): Add flash-multiboot.sh download/flash tool
- Download latest multiboot image from GitHub releases
- SHA256 checksum verification
- Flash to USB with progress and confirmation
- Supports --list, --download, --release, --force options
- Document in scripts/README.md

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-27 19:12:23 +02:00
d42745aac3 feat(live-boot): Complete live RAM boot implementation v2.2.4-live
- Install live-boot package and rebuild initramfs with live-boot scripts
- Create squashfs filesystem (878MB) on data partition sda4
- Update boot.scr with live boot parameters (boot=live, toram)
- Fix wiki sidebar links from [[Page|Display]] to [Display](Page)
- Add Eye-Remote wiki page documentation
- Add sync-wiki.sh script for wiki repository sync
- Add patch-multiboot-efi.sh for post-build EFI patching

Partition layout:
- sda1 (512MB): EFI with kernel, initrd, dtbs, boot.scr
- sda2 (3GB): ARM64 rootfs reference
- sda3 (3GB): x86 rootfs for VirtualBox/QEMU
- sda4 (9.5GB): Data + /live/filesystem.squashfs

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-27 13:30:50 +02:00
29595a64d3 docs: Add TOOLS.md and missing README files
- docs/TOOLS.md: Complete reference of all build/generation tools
- scripts/README.md: Documentation for scripts directory
- remote-ui/README.md: Documentation for remote-ui module

Also fix build-storage-img.sh to use same slipstream logic as
build-ebin-live-usb.sh:
- Search packages in output/debs AND ~/.cache/secubox/debs
- Use dpkg -i --force-depends --force-overwrite (faster)
- Install all packages at once instead of per-package apt

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-26 20:38:29 +02:00
fd86a6709f fix(build): Add timeouts to prevent build script hangs
- Add 5 min timeout per package in dpkg-buildpackage calls
- Add 10-20 min timeout for QEMU chroot apt operations
- Add 45 min timeout for sub-script execution
- Add 15 min timeout with retries for wget downloads
- Fix pipe to tail pattern that swallowed exit codes
- Add progress logging for QEMU package installation
- Use writable log directory (output/logs) instead of /tmp
- Add --verbose flag to build-eye-remote-full.sh
- Export VERBOSE for sub-scripts

Fixes hangs caused by:
- dpkg-buildpackage | tail -5 buffering issues
- QEMU chroot apt-get with no timeout
- Network operations with no timeout

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-26 19:04:20 +02:00
cf7ea44c78 fix(kiosk): Skip X11 config on bare metal, disable service sandboxing
- X11 setup now exits early for bare metal (VM_TYPE=none) without
  creating config files - Intel/AMD/NVIDIA auto-detect perfectly
- Remove static fallback 10-modesetting.conf that caused conflicts
- Sanitize GPU_INFO in config comments to remove special chars
- Disable PrivateTmp and ProtectSystem for haproxy, metrics, threats
  services - causes Python symlink namespace errors on some kernels
- Add fix-namespace-errors.sh script for quick fixes on running systems

Fixes: X11 "no screens found" on Intel HD Graphics 630
Fixes: "Failed to set up mount namespacing" for Python services

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-15 09:52:20 +02:00
4165d6d66c feat(network): Smart auto-IP with ARP collision detection (v1.7.0.2)
- Add ARP-based IP collision detection for multi-device environments
- MAC-based pseudo-random IP offset to spread devices across range
- Gratuitous ARP announcement to prevent IP conflicts
- Fix EspressoBin DSA network: target wan interface, not eth0 CPU port
- Static IP fallback 192.168.255.250 when DHCP unavailable
- Sync all build scripts to version 1.7.0
- Add screenshot script with 90+ module URLs
- Add mock HTML screenshots for documentation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-14 16:28:02 +02:00
7a34189ed4 feat(kiosk): Add VirtualBox debug logging for X11 troubleshooting
- Add generate_debug_report() to secubox-kiosk-launcher
- Capture system info, virtualization, graphics hardware
- Log DRM/KMS devices, kernel modules, Xorg status
- Enhanced error reporting with dmesg and VT status
- Debug reports saved to /tmp/kiosk-debug-*.log
- Add v1.6.7.2 overlay installer scripts
- Add emoji font fixes for navbar icons
- Add screenshots for v1.6.7.1

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-13 08:26:06 +02:00
f9628d8aef fix(ui): Add sidebar navigation to 11 modules
Fixed UI guideline compliance for modules missing sidebar:
- secubox-cloner, wazuh, ossec, vault, magicmirror
- secubox-mmpm, redroid, rezapp, vm, ndpid, p2p

Changes per module:
- Added <nav class="sidebar" id="sidebar"></nav>
- Added body class="crt-light"
- Added sidebar.js script reference (ndpid)

Also added:
- REPORT-2026-04-10.md: Board/financer status report
- scripts/ui-screenshot-capture.py: Playwright UI capture
- scripts/ui-fix-checker.sh: UI guideline compliance checker

UI checker now passes 120/120 modules.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-10 13:20:24 +02:00
ac7f8a0d7e feat: Add QEMU/VBox launcher scripts + fix kiosk log bug
New scripts:
- scripts/run-qemu.sh: Launch SecuBox in QEMU with port forwarding
- scripts/run-vbox.sh: Create and launch SecuBox VM in VirtualBox

Port forwarding (both scripts):
- SSH:   localhost:2222 → guest:22
- HTTPS: localhost:9443 → guest:443
- HTTP:  localhost:8080 → guest:80

Bug fix:
- secubox-kiosk-launcher: log() now writes to stderr
- Fixes URL corruption when log messages were captured by
  command substitution in determine_url()

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-10 12:02:25 +02:00
34b51bbf8e feat: Implement 6-Module Design System across all UI components
Complete UI design compliance update based on SecuBox Charte Graphique:

Design System:
- Add design-tokens.css with 6-module color system (BOOT/AUTH/ROOT/MIND/MESH/WALL)
- Update crt-light.css, crt-system.css for light/dark theme tokens
- Update sidebar.css, sidebar-light.css with module accent colors
- Refactor crt-components.js web components to use CSS variables

Module CSS Updates (35 files):
- All module CSS files now import design-tokens.css
- Replace hardcoded P31 Phosphor colors with CSS variables
- Add shared symlinks from each package to hub shared assets

UI Components:
- Redesign login.html with 6-module design system
- Update hub index.html dashboard with design tokens
- Remove legacy P31 color variables

System Branding:
- Add /etc/issue, /etc/issue.net, /etc/motd with 6-module branding
- Create Plymouth boot splash theme (secubox + secubox-text)
- Add generate-plymouth-assets.sh for theme image generation

Tools:
- Add update-css-design-tokens.py for batch CSS updates

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-08 18:29:36 +02:00
b153527b96 docs: Add VirtualBox quick start guide and VM creation script
New files:
- wiki/Live-USB-VirtualBox.md: Complete guide from download to running VM
- scripts/create-secubox-vm.sh: Automated VM creation with port forwarding
- templates/SecuBox-Live.vbox.template: VirtualBox template file

Updates:
- README.md: Added VirtualBox quick start section, updated package count (93)
- wiki/_Sidebar.md: Added VirtualBox quick start link

Usage:
  ./scripts/create-secubox-vm.sh secubox-live.vdi
  ./scripts/create-secubox-vm.sh --download --headless

Access after boot:
  SSH:  ssh -p 2222 root@localhost
  Web:  https://localhost:9443
  Pass: secubox

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-04-04 10:31:21 +02:00
4136a6d9b8 feat(build): Slipstream ALL packages, AZERTY, no-compress option
- build-all-local.sh: Discover and build ALL 93 packages dynamically
- build-live-usb.sh: Install ALL packages from cache
- List and verify all installed packages during build
- Save installed packages list to /var/lib/secubox/installed-packages.txt
- Add --no-compress option to skip gzip for local testing
- AZERTY keyboard already configured (fr layout)
- Update WebUI URL to use dummy interface (192.168.255.1:9443)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-30 06:37:35 +02:00
9cb679c221 fix(network): Add dummy interface and DHCP fallback for kiosk
- Add dummy0 interface with fixed IP 192.168.255.1/24
- Always available for kiosk/local access regardless of DHCP
- Add optional: true to DHCP config to prevent boot blocking
- Add secubox-net-fallback service for link-local IP fallback
- Update kiosk URL to use dummy interface IP
- Fix build-all-local.sh arithmetic expression bug

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-30 06:28:53 +02:00
7db62c52f9 fix(identity): Correct cryptography API for PublicKeyFormat
- Change serialization.PublicKeyFormat.Raw to PublicFormat.Raw
- Change PublicKeyFormat.SubjectPublicKeyInfo to PublicFormat.SubjectPublicKeyInfo
- Fixes service crash on startup due to AttributeError

feat(build): Add new packages to build script

- Added secubox-ndpid, secubox-system-hub
- Added AI modules: ai-gateway, localrecall, master-link, threat-analyst
- Added security modules: cve-triage, network-anomaly, dns-guard, iot-guard
- Added config-advisor, mcp-server, identity, ad-guard

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-27 10:23:31 +01:00
9a105d1758 Fix p2p/zkp/mesh navbar and add fix-navbar.sh script
- Added crt-light.css to p2p, zkp, mesh pages
- Fixed body class to crt-light
- Removed duplicate WireGuard menu entry on VM
- Added scripts/fix-navbar.sh for automated navbar integration checks

Required navbar elements:
1. crt-light.css and sidebar-light.css links
2. body class="crt-light"
3. <nav class="sidebar" id="sidebar"></nav>
4. /shared/sidebar.js script

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-26 07:19:29 +01:00
cbe7e4ac3a Add CRT light theme across all UI modules
- Create crt-light.css with lighter P31 phosphor colors
- Create sidebar-light.css matching light theme
- Update 49 HTML files to use light theme CSS
- Add apply-light-theme.py script for automated theme application

Theme changes:
- Background: #050803 (dark) -> #e8f5e9 (mint green)
- Cards: #080d05 -> #c8e6c9 (pale green)
- P31 peak: #33ff66 -> #00dd44 (darker for contrast)
- Font: JetBrains Mono / Courier Prime

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-25 08:55:45 +01:00
d703393fb6 Add preseed system for configuration persistence
New files:
- scripts/export-preseed.sh: Export config from running system
- image/preseed-apply.sh: Apply preseed on firstboot
- image/secubox-preseed.service: Systemd service for preseed

Features:
- Export SecuBox config (/etc/secubox/)
- Export network config (netplan, WireGuard)
- Export user accounts and SSH keys
- Export service configs (nginx, HAProxy, CrowdSec)
- Export SSL certificates
- Apply on firstboot with systemd service

Usage:
  # On running VM, export config:
  ./scripts/export-preseed.sh my-config.tar.gz

  # Build live USB with preseed:
  sudo bash image/build-live-usb.sh --preseed my-config.tar.gz

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-24 19:41:08 +01:00
a4fa81d349 Add complete package READMEs and multilingual wiki documentation
- Generate README.md for all 45 secubox-* packages with screenshots
- Add multilingual wiki pages (EN, FR, DE, ZH) documenting 47 modules
- Add generate-docs.py tool for documentation generation

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-24 15:31:34 +01:00
c1e4b45d47 Fix screenshot tool login with aiohttp
- Use aiohttp to login via API (bypasses browser SSL issues)
- Inject JWT token into browser localStorage
- All 45 modules now captured with proper authentication
- Portal service watchdog needed (keeps dying)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-24 13:24:30 +01:00
1f2386b1a8 Update screenshots and wiki documentation
- Refreshed all 45 VM module screenshots
- Updated screenshot-tool.py with better login selectors
- Wiki documentation ready in docs/wiki/
  - secubox-debian-ui.md
  - secubox-openwrt-ui.md
  - UI-COMPARISON.md

Screenshots gallery: docs/SCREENSHOTS-VM.md

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-24 13:04:43 +01:00
948003c307 Add screenshot tool and wiki documentation
scripts/screenshot-tool.py:
- Playwright-based screenshot capture for all 47 modules
- Supports VM (localhost:9443) and device (192.168.255.1)
- Auto-login with JWT token handling
- Generates markdown documentation per host
- Side-by-side comparison generator
- Wiki page generators for both repositories
- Module listing with categories and icons

docs/wiki/:
- secubox-openwrt-ui.md: OpenWRT LuCI documentation
- secubox-debian-ui.md: Debian CRT P31 theme documentation
- UI-COMPARISON.md: Side-by-side comparison guide

Usage:
  python3 scripts/screenshot-tool.py --host vm
  python3 scripts/screenshot-tool.py --host device
  python3 scripts/screenshot-tool.py --compare --all

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-24 12:36:19 +01:00
e3ef51ba8b Apply CRT P31 Phosphor theme to all 38 module UIs
Converted all SecuBox module frontends to CRT design system:
- P31 Phosphor color palette (green phosphor with amber accents)
- Bloom text-shadow effects on headers and active elements
- Monospace Courier Prime typography throughout
- Dark tube glass backgrounds (#050803, #080d05)
- CRT overlays (scanlines, vignette via body classes)

Updated components across all modules:
- Buttons: CRT border glow on hover
- Cards: Inset shadows, ghost borders
- Tables: Amber headers, green data rows
- Badges: Phosphor glow variants
- Modals: Dark backdrop, dim border
- Tabs: Uppercase with letter-spacing
- Forms: Dark inputs with focus glow

Each module now includes:
- crt-system.css (design tokens)
- crt-engine.js (typewriter, audio, toasts)
- Courier Prime font preconnect
- body.crt-body.crt-scanlines classes

Modules updated (38):
auth, backup, c3box, cdn, crowdsec, dns, dpi, droplet,
exposure, gitea, haproxy, hardening, hub, mail, mail-lxc,
mediaflow, metablogizer, mitmproxy, nac, netdata, netmodes,
nextcloud, portal, publish, qos, repo, streamforge, streamlit,
system, tor, traffic, users, vhost, waf, watchdog, webmail,
webmail-lxc, wireguard

Added: scripts/apply-crt-theme.py for future theme updates

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-23 18:56:11 +01:00
d7c8cc19e9 Add secubox-repo and secubox-hardening modules, CI/CD workflows
New modules (35 total):
- secubox-repo v1.0.0: APT repository management
  - repoctl CLI for package management
  - GPG key generation and signing
  - Multi-distribution support (bookworm, trixie)
  - Web dashboard for repository status

- secubox-hardening v1.0.0: Kernel and system hardening
  - hardeningctl CLI for security management
  - Sysctl hardening (ASLR, kptr_restrict, SYN cookies)
  - Module blacklist (uncommon protocols, filesystems)
  - Security benchmark with 100% score on VM

CI/CD workflows:
- build-packages.yml: Dynamic matrix for all packages
- build-image.yml: 5 board images with compression
- publish-packages.yml: APT repo publishing
- release.yml: Unified release orchestration

APT repository scripts:
- export-secrets.sh: Export GPG/SSH keys for GitHub Actions
- local-publish.sh: Local test server
- install.sh: User installation script

Security (Phase 5):
- AppArmor profiles for all services
- Audit rules for SecuBox services
- build-all.sh for local builds

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-22 22:15:01 +01:00
a78e9aa24b chore: update build-all-local.sh with all 30 packages
Added all new packages to the build script in dependency order:
- Core: portal, system
- Security: waf
- Network: haproxy, dns
- Publishing: droplet, streamlit, streamforge, metablogizer, publish
- Email: mail, mail-lxc, webmail, webmail-lxc, users

All 30 packages build and deploy successfully.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-21 21:32:09 +01:00
7c42a80baf feat: modular nginx config + hub roadmap + new modules
Nginx architecture:
- Modular config: each module installs /etc/nginx/secubox.d/<module>.conf
- Auto-register on install, auto-remove on purge
- Main config includes from secubox.d/*.conf
- 27 module snippets for dynamic component management

Hub enhancements:
- Add roadmap widget showing migration progress (84% complete)
- Add /api/v1/hub/roadmap endpoint with category breakdown
- Shared sidebar.css for consistent styling across modules

New modules:
- secubox-portal: JWT authentication, session management
- secubox-dns: DNS server management
- secubox-mail: Mail server (Postfix) management
- secubox-webmail: Roundcube webmail
- secubox-users: User account management
- secubox-publish: Content publishing
- secubox-waf: Web Application Firewall
- secubox-mail-lxc: Mail LXC container
- secubox-webmail-lxc: Webmail LXC container

Debian packaging:
- All modules updated with modular nginx support
- postinst: creates secubox.d/, reloads nginx
- prerm: removes snippet, reloads nginx
- rules: installs nginx/<module>.conf

Scripts:
- new-package.sh: generates modular nginx files for new modules
- retrofit-nginx-modular.sh: updates existing packages

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-21 20:34:01 +01:00
065560326d fix: complete CSS variables and add module scaffold skill
- Add missing --cyan, --yellow, --purple CSS vars to metablogizer,
  streamlit, streamforge, haproxy, vhost frontends
- Create /module skill for scaffolding new SecuBox modules
- Add new-module.sh script with complete package template
- Clean up debian build artifacts from git
- Update .gitignore for debian build dirs

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-21 18:27:21 +01:00
bf1babb37c Initial commit: SecuBox-DEB migration from OpenWrt to Debian
Includes all package APIs with public dashboard endpoints:
- secubox-system: System Hub with /info, /resources, /security
- secubox-crowdsec: CrowdSec dashboard with /status, /hub, /metrics, actions
- secubox-wireguard: WireGuard VPN with /interfaces, /peers, start/stop
- secubox-netdata: Monitoring with /stats, /processes, /alerts

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-03-21 09:41:06 +01:00