SecuAAS Docs

Detailed Technical Stack

SecuFile — Detailed Technical Stack

Detailed Technical Stack

Detailed Technical Stack

Go Backend (filesecure)

Language and Frameworks

TechnologyVersionUsage
Go1.25Primary language
Ginv1.10+HTTP/REST framework
pgx/v5v5.7+PostgreSQL driver (connection pool)
go-redis/v9v9.7+Redis client
aws-sdk-go-v2latestOVH S3 client
golang-migratev4Database migrations
prometheuslatestMetrics
golang.org/x/cryptov0.48.0Cryptography (HKDF, OAEP)
stripe-gov82Stripe integration

Go Project Structure

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

WebGUI Backend (Python)

Language and Frameworks

TechnologyVersionUsage
Python3.11+Language
FastAPI0.100+Async API framework
asyncpglatestAsync PostgreSQL driver
httpxlatestAsync HTTP client
ovh1.2.0OVH API client (billing)
resendlatestEmail sending API

Python Project Structure

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

React Frontend

Language and Frameworks

TechnologyVersionUsage
React18UI framework
React Routerv6Routing
Tailwind CSS3Styling
shadcn/uilatestUI components
RechartslatestCharts
AxioslatestHTTP client
TinyMCElatestRich text editor
Stripe.jslatestPayment elements

React Project Structure

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
|   +-- ...

On this page