Centralized management hub for monitoring, controlling, and licensing all Ogur applications with REST API and real-time SignalR communication.
- Application Management: Register and track Ogur applications with version control
- License Management: 1 license = 1 account = N devices (configurable), HWID + GUID tracking
- Device Management: Track, block, and remotely control connected devices
- Real-time Communication: SignalR hub for pushing commands to applications
- User Management: JWT-based authentication with role-based access control (Admin/User)
- Audit Logging: Complete audit trail of all operations
- Telemetry: Receive and analyze application event data
- VPS Monitoring: Docker container stats, resource usage, website management
- JWT Authentication: Web panel users (24h token expiration)
- API Key Authentication: Applications (SHA256 hashed)
- Role-Based Access Control: Admin vs. User permissions
- Device Fingerprinting: HWID + GUID for unique device identification
- Health Checks: Application version tracking and update notifications
- Remote Commands: Logout, block device, send notifications, force updates
- Session Tracking: SignalR connection monitoring with IP address logging
- Usage Statistics: Device sessions, validation counts, telemetry events
- VPS Dashboard: Real-time CPU, RAM, disk usage, container management
- .NET 8 with C# 12
- ASP.NET Core Web API - REST endpoints
- SignalR - Real-time bidirectional communication
- Entity Framework Core 8 - Code-First ORM
- MariaDB (MySQL) via Pomelo.EntityFrameworkCore.MySql
- Serilog - Structured logging
- MediatR - CQRS pattern
- ASP.NET Core MVC - Server-side rendering
- DevExpress - Professional UI components
- Bootstrap 5.3 - Responsive framework
- SignalR Client - Real-time dashboard updates
- Chart.js - VPS monitoring visualizations
- Clean Architecture - Domain, Application, Infrastructure, API layers
- CQRS - Command Query Responsibility Segregation
- DDD - Domain-Driven Design patterns
- Repository Pattern - Generic
IRepository<T>with EF Core - Value Objects -
LicenseKey,ApiKey,DeviceFingerprint
- Ogur.Core - Client-side integration library
- Ogur.Abstractions - Shared interfaces and contracts
Ogur.Hub.sln
├── Ogur.Hub.Domain/ # Domain entities, value objects, enums
├── Ogur.Hub.Application/ # Business logic, CQRS handlers, DTOs
├── Ogur.Hub.Infrastructure/ # EF Core, repositories, SignalR hubs
├── Ogur.Hub.Api/ # REST API + SignalR endpoints
├── Ogur.Hub.Web/ # DevExpress web panel (MVC)
└── Ogur.Hub.Tests/ # Unit & integration tests
| Table | Purpose |
|---|---|
Applications |
Registry of all Ogur applications |
Users |
Web panel user accounts |
Licenses |
License management (1:1 with users, 1:N with devices) |
Devices |
Device registrations with HWID + GUID |
DeviceSessions |
SignalR connection tracking |
DeviceUsers |
Many-to-many device-user assignments |
ApplicationVersions |
Version history per application |
Telemetry |
Event logs from applications |
AuditLogs |
Complete audit trail |
HubCommands |
Command history sent to devices |
VpsContainers |
Docker container monitoring |
VpsResourceSnapshots |
Historical resource usage |
VpsWebsites |
Managed websites (Traefik integration) |
- .NET 8 SDK
- MariaDB 10.6+ (or MySQL 8.0+)
- Docker & Docker Compose (optional)
- Clone repository
git clone https://github.com/ishkabar/ogurbot-hub.git
cd ogurbot-hub- Configure database
Edit Ogur.Hub.Api/appsettings.json:
{
"ConnectionStrings": {
"DefaultConnection": "Server=localhost;Port=3306;Database=ogurhub;User=root;Password=yourpassword;"
}
}- Run migrations
cd Ogur.Hub.Api
dotnet ef database update -p ../Ogur.Hub.Infrastructure- Create admin user
-- Generate BCrypt hash for your password first
INSERT INTO Users (Username, Email, PasswordHash, IsAdmin, IsActive, CreatedAt, UpdatedAt)
VALUES ('admin', 'admin@ogurhub.local', 'YOUR_BCRYPT_HASH', 1, 1, NOW(), NOW());- Run services
# API
dotnet run --project Ogur.Hub.Api
# Web Panel (separate terminal)
dotnet run --project Ogur.Hub.Web- Access
- API:
http://localhost:5180/swagger - Web Panel:
http://localhost:5001
# Build and run
docker-compose up -d
# View logs
docker-compose logs -f api web
# Stop services
docker-compose downPOST /api/auth/login- JWT login for web panel usersPOST /api/auth/register- Register new user
GET /api/applications- List all applicationsPOST /api/applications- Register new applicationGET /api/applications/{id}- Get application detailsPUT /api/applications/{id}- Update application
POST /api/licenses/validate- Validate license + register/update deviceGET /api/licenses- List licensesPOST /api/licenses- Create new licensePATCH /api/licenses/{id}- Update licensePOST /api/licenses/{id}/extend- Extend expirationPOST /api/licenses/{id}/revoke- Revoke license
GET /api/devices- List devicesPOST /api/devices/{id}/block- Block devicePOST /api/devices/{id}/unblock- Unblock devicePOST /api/devices/{id}/logout- Force logoutPOST /api/devices/{id}/command- Send custom command
GET /api/updates/check- Check for application updates
POST /api/telemetry- Receive telemetry batchGET /api/telemetry- Query telemetry logs
GET /api/audit- Query audit logs
GET /api/vps/resources- Current resource usageGET /api/vps/containers- Docker container listGET /api/vps/websites- Managed websites
Client → Server:
Heartbeat()- Periodic ping from client
Server → Client:
ReceiveCommand(HubCommand)- Push command to client- Command types:
Logout,BlockDevice,Notify,ForceUpdate,RefreshLicense,Custom
Client → Server (Acknowledgment):
AcknowledgeCommand(commandId)- Confirm execution
Server → Client:
ReceiveResourceUpdate(VpsResourceDto)- Real-time resource statsReceiveContainerUpdate(List<VpsContainerDto>)- Container status changes
Domain entities, value objects, and business rules.
Business logic, CQRS handlers, and DTOs.
EF Core, repositories, SignalR hubs, and background services.
REST API and SignalR endpoints.
DevExpress-based admin panel.
ASPNETCORE_ENVIRONMENT=Development
ConnectionStrings__DefaultConnection=Server=localhost;Database=ogurhub;User=root;Password=pass;
Jwt__SecretKey=your-secret-key
Jwt__Issuer=OgurHub
Jwt__Audience=OgurHubClientsASPNETCORE_ENVIRONMENT=Development
HubApi__BaseUrl=http://localhost:5180# Run all tests
dotnet test
# Run with coverage
dotnet test /p:CollectCoverage=true- Redis caching layer
- Rate limiting per API key
- Advanced telemetry analytics
- Multi-tenancy support
- Two-factor authentication (2FA)
- Webhook notifications
- GraphQL API
- Mobile monitoring app
Proprietary - All rights reserved © 2025 Dominik Karczewski (ogur.dev)
Dominik Karczewski