Detailed Technical Stack
SecuFile — Detailed Technical Stack
| Technology | Version | Usage |
|---|
| Go | 1.25 | Primary language |
| Gin | v1.10+ | HTTP/REST framework |
| pgx/v5 | v5.7+ | PostgreSQL driver (connection pool) |
| go-redis/v9 | v9.7+ | Redis client |
| aws-sdk-go-v2 | latest | OVH S3 client |
| golang-migrate | v4 | Database migrations |
| prometheus | latest | Metrics |
| golang.org/x/crypto | v0.48.0 | Cryptography (HKDF, OAEP) |
| stripe-go | v82 | Stripe integration |
filesecure/backend/
+-- cmd/
| +-- api/main.go # Main entry point
| +-- cleanup-s3/main.go # S3 cleanup tool
| +-- init-keys/main.go # RSA key initialization
+-- internal/
| +-- config/config.go # Configuration (env vars)
| +-- database/ # PostgreSQL connection and migrations
| +-- handlers/ # 47 HTTP handler files
| | +-- auth.go # Authentication (login, register, MFA, SSO)
| | +-- file.go # File operations
| | +-- folder.go # Folder management
| | +-- sharelink.go # Share links
| | +-- organization.go # Multi-tenant organizations
| | +-- subscription.go # SaaS subscriptions
| | +-- stripe_webhook.go # Stripe webhooks
| | +-- ...
| +-- middleware/ # HTTP middlewares
| | +-- auth.go # JWT authentication
| | +-- csrf.go # CSRF protection (Content-Type)
| | +-- rate_limit.go # Rate limiting (Redis + in-memory)
| | +-- logging.go # Request logging (slog)
| | +-- metrics.go # Prometheus HTTP metrics
| | +-- body_limit.go # Body size limit (1MB/25MB)
| +-- models/models.go # Data models
| +-- services/ # 64 service files
| +-- auth.go # Authentication logic
| +-- file.go # File logic
| +-- file_client_encryption.go # Client-side encryption
| +-- rsa_keys.go # RSA key management + KMS
| +-- organization.go # Multi-tenant logic
| +-- stripe_integration.go # Stripe integration
| +-- ...
+-- pkg/
| +-- crypto/crypto.go # AES-256-GCM, KMS wrapping
| +-- kms/ # KMS provider abstraction
| +-- logging/logging.go # slog setup (JSON/text)
| +-- metrics/metrics.go # Prometheus definitions
| +-- ovh/ # OVH client (storage provisioning)
| +-- secretsloader/ # Secrets loading
| +-- storage/s3.go # S3 client (upload, download, streaming)
+-- migrations/ # 26 SQL migrations (up/down)
+-- Dockerfile # Multi-stage Go build
| Technology | Version | Usage |
|---|
| Python | 3.11+ | Language |
| FastAPI | 0.100+ | Async API framework |
| asyncpg | latest | Async PostgreSQL driver |
| httpx | latest | Async HTTP client |
| ovh | 1.2.0 | OVH API client (billing) |
| resend | latest | Email sending API |
filesecure-webgui/backend/
+-- server.py # FastAPI entry point
+-- config.py # Configuration
+-- db_postgres.py # PostgreSQL connection
+-- email_service.py # 6 HTML email templates
+-- models.py # Pydantic models
+-- routes/ # 26 route modules
| +-- auth.py # Authentication proxy
| +-- share.py # Share links proxy
| +-- transfers.py # Transfers
| +-- admin_dashboard.py # Superadmin dashboard
| +-- sso.py # Zitadel SSO (OIDC)
| +-- audit.py # Audit logs
| +-- ...
+-- services/
| +-- ovh_billing.py # OVH S3 billing
+-- utils/
| +-- audit.py # Audit logger
| +-- scheduler.py # Periodic S3 collection
+-- migrations/ # WebGUI migrations
| Technology | Version | Usage |
|---|
| React | 18 | UI framework |
| React Router | v6 | Routing |
| Tailwind CSS | 3 | Styling |
| shadcn/ui | latest | UI components |
| Recharts | latest | Charts |
| Axios | latest | HTTP client |
| TinyMCE | latest | Rich text editor |
| Stripe.js | latest | Payment elements |
filesecure-webgui/frontend/src/
+-- App.js # Main routes
+-- contexts/
| +-- AuthContext.jsx # Authentication (JWT)
| +-- EncryptionContext.jsx # Client-side encryption
| +-- LanguageContext.jsx # Internationalization
| +-- StripeContext.jsx # Stripe Elements integration
+-- pages/
| +-- DashboardPage.jsx # Dashboard (share links, metrics)
| +-- FilesPage.jsx # File manager
| +-- ShareLinkPage.jsx # Public share link page
| +-- TransferPage.jsx # Public transfer page
| +-- UsersPage.jsx # User management
| +-- SubscriptionPage.jsx # Subscription management
| +-- AuditLogsPage.jsx # Audit logs
| +-- admin/ # Administration pages
| +-- public/ # Public marketing pages
+-- components/
| +-- StorageDashboard.jsx # S3 superadmin dashboard
| +-- CreateTransferDialog.jsx # Transfer creation dialog
| +-- EncryptedUploadDialog.jsx # Encrypted upload
| +-- Sidebar.jsx # Side navigation
| +-- ...