3322 Commits

Author SHA1 Message Date
Oliver Kieselbach 2001dbaa29 prevent PII detail leaks 2026-02-07 22:25:06 +01:00
Oliver Kieselbach 3a46310cba limit json body size to protect functions 2026-02-07 22:15:29 +01:00
Oliver Kieselbach 4b48664ee0 limit tenantconfig cache 2026-02-07 22:07:34 +01:00
Oliver Kieselbach 25715bbf3f rework to avoid duplicate code in SignlR 2026-02-07 22:02:46 +01:00
Oliver Kieselbach a7e12b3588 Middleware security fix 2026-02-07 21:56:13 +01:00
Oliver Kieselbach 89fb50368e ConfigManagerCache fix 2026-02-07 21:41:25 +01:00
Oliver Kieselbach ef2190c687 fixed galactic admin check in signalrgroup join/leave 2026-02-07 21:34:56 +01:00
Oliver Kieselbach 7fae27f0da handle OData filer injection 2026-02-07 21:26:49 +01:00
Oliver Kieselbach 5f4519d635 DailyMaintananceFunction restructuring 2026-02-07 20:54:48 +01:00
Oliver Kieselbach f358d8ebd9 Central table creation logic
app install metrics
platform stats
global gather and analyze rule editng
Dark mode (needs improvement)
UI enhancments
2026-02-07 19:23:20 +01:00
Oliver Kieselbach 994324f833 Central table creation logic
app install metrics
platform stats
global gather and analyze rule editng
Dark mode (needs improvement)
UI enhancments
2026-02-07 19:22:49 +01:00
Oliver Kieselbach 339cfda9ef changed analyze rule execution logic 2026-02-06 19:21:15 +01:00
Oliver Kieselbach 6c72adb391 Add advanced monitoring, rule engine, and interactive session visualizations
Key Changes:
Web Portal:

Interactive performance metrics with 4-column responsive grid (CPU, Memory, Disk Queue, Disk Free)
Sparklines with hover tooltips using ResizeObserver for pixel-perfect rendering
Collapsible download progress tracking with ETA calculations
Event timeline severity filters (Debug, Info, Warning, Error, Critical)
Backend - Rule Engine:

Gather Rules: Remote-configurable data collection (Command/Registry/WMI)
Analyze Rules: Pattern-based event analysis for common failure scenarios
Built-in rules for Network, Identity, MDM, Apps, ESP diagnostics
Fix: Seed logic now updates existing rules when code definitions change
Agent - New Collectors:

Performance, Download Progress, Cert Validation, ESP UI State collectors
Gather Rule Executor with command allowlist enforcement
Remote Config Service for dynamic agent configuration
Session persistence across agent restarts
2026-02-06 18:46:58 +01:00
Oliver Kieselbach 665c9288fa Add mass rollout simulator and tenant suspension features
- Agent: Add --simulator-mass-rollout mode for parallel device enrollment testing (5 devices across 3 tenants)
- Backend: Add tenant suspension/disable functionality with optional time-based auto-reactivation
- Backend: Add TenantAdminsService and new API endpoints for tenant configuration management
- Frontend: Extend admin configuration UI with tenant management features
2026-02-06 02:36:13 +01:00
Oliver Kieselbach d7fdef39d6 agent session id persistence 2026-02-05 23:31:02 +01:00
Oliver Kieselbach c2a7c28eec more hardenings 2026-02-05 22:12:45 +01:00
Oliver Kieselbach 064319334d Signing fix 2026-02-05 22:02:12 +01:00
Oliver Kieselbach 557dd22c53 Authentication & Galactic Admin: Implement JWT-based multi-tenant access control with cross-tenant support
Backend Changes:
- Fix user identification to use UPN (User Principal Name) claim as primary identifier instead of display name
- Add JWT authentication validation to all API endpoints with Authorization header support
- Implement Galactic Admin role with cross-tenant access permissions for sessions, events, and SignalR groups
- Add cross-tenant validation in GetSessionEventsFunction, SignalRAddToGroupFunction, and SignalRRemoveFromGroupFunction
- Enhance AuthenticationMiddleware to log actual user identifier (UPN) instead of display name

Admin Configuration:
- Add GetAdminConfigurationFunction and UpdateAdminConfigurationFunction for global settings
- Create AdminConfigurationService for managing platform-wide configuration
- Add AdminConfiguration model with global rate limiting and maintenance settings
- Restrict admin configuration access to Galactic Admins only

SignalR Real-time Updates:
- Implement "galactic-admins" SignalR group for cross-tenant session visibility
- RegisterSessionFunction now sends "newSession" events to both tenant-specific and galactic-admins groups
- IngestEventsFunction sends "newevents" only to tenant-specific groups (prevents flooding)
- Frontend listens to both "newSession" and "newevents" for real-time updates
- Galactic Admins see new sessions from all tenants without being flooded with event updates

Frontend Changes:
- Add Authorization headers with JWT tokens to all API fetch calls (sessions, events, metrics, configuration)
- Implement automatic joining/leaving of "galactic-admins" SignalR group based on Galactic Admin mode
- Handle both "newSession" and "newevents" SignalR events for complete session list updates
- Add authentication error handling with user notifications for token failures

Security Improvements:
- Validate tenant access for all cross-tenant operations
- Ensure users can only access their own tenant data unless they're Galactic Admins
- Log all cross-tenant access attempts with user identifiers for audit trail
2026-02-05 20:49:36 +01:00
Oliver Kieselbach a20ff48ae6 Backend:
- Add JWT-based authentication to all API endpoints
- Implement tenant isolation and access control validation
- Add Galactic Admin role validation for cross-tenant endpoints
- Enhance certificate validation with full X.509 chain checking
- Add certificate validation cache (5-min TTL) and self-signed cert protection
- Implement NDJSON payload size limit protection (configurable per tenant)
- Replace placeholder audit user identifiers with actual JWT user principals
- Add TenantHelper utility for consistent tenant/user extraction from tokens
- Disable PII logging in production (ShowPII = false)

Agent:
- Add automatic tenant ID detection from Windows Registry (AAD Join enrollment)
- Implement tenant ID precedence: CLI argument > Registry > Fallback

SignalR:
- Add authentication checks to all SignalR functions
- Implement tenant-based group access control
- Add user identifier logging for SignalR operations

Frontend:
- Change MSAL cache from localStorage to sessionStorage (XSS protection)
- Add warning status support to health check page
- Add Admin Configuration link in navbar (Galactic Admin only)
- Move maintenance trigger from Settings to Admin Configuration page
- Update tenant context logging for clarity

Configuration:
- Add MaxNdjsonPayloadSizeMB setting to TenantConfiguration model
- Update configuration service to persist new retention/timeout settings
2026-02-05 16:38:16 +01:00
Oliver Kieselbach 8cc6823533 Agent parameter logic fix 2026-02-05 12:08:47 +01:00
Oliver Kieselbach db55809b49 Bootstrap
- install only during enrollment
Agent
- added geolocation support
- HelloDetector
- Reboot on complete
- WMI Model parsing fix
...and general small additions here and there
2026-02-05 12:03:22 +01:00
Oliver Kieselbach 5690620058 Initial commit 2026-02-05 06:14:41 +01:00