SecuAAS Docs
SecuFile

Stack technique détaillée

Technologies et frameworks utilisés

Stack technique detaillee

Book: SecuFile — Stockage sécurisé de fichiers | Chapter: Architecture

Stack technique detaillee

Backend Go (filesecure)

Langage et frameworks

TechnologieVersionUsage
Go1.25Langage principal
Ginv1.10+Framework HTTP/REST
pgx/v5v5.7+Driver PostgreSQL (connection pool)
go-redis/v9v9.7+Client Redis
aws-sdk-go-v2latestClient S3 OVH
golang-migratev4Migrations de base de donnees
prometheuslatestMetriques
golang.org/x/cryptov0.48.0Cryptographie (HKDF, OAEP)
stripe-gov82Integration Stripe

Structure du projet Go

filesecure/backend/
+-- cmd/
|   +-- api/main.go              # Point d'entree principal
|   +-- cleanup-s3/main.go       # Outil de nettoyage S3
|   +-- init-keys/main.go        # Initialisation cles RSA
+-- internal/
|   +-- config/config.go         # Configuration (env vars)
|   +-- database/                # Connexion et migrations PostgreSQL
|   +-- handlers/                # 47 fichiers de handlers HTTP
|   |   +-- auth.go              # Authentification (login, register, MFA, SSO)
|   |   +-- file.go              # Operations fichiers
|   |   +-- folder.go            # Gestion dossiers
|   |   +-- sharelink.go         # Liens de partage
|   |   +-- organization.go      # Organisations multi-tenant
|   |   +-- subscription.go      # Abonnements SaaS
|   |   +-- stripe_webhook.go    # Webhooks Stripe
|   |   +-- ...
|   +-- middleware/              # Middlewares HTTP
|   |   +-- 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         # Modeles de donnees
|   +-- services/                # 64 fichiers de services
|       +-- auth.go              # Logique d'authentification
|       +-- file.go              # Logique fichiers
|       +-- file_client_encryption.go  # Chiffrement cote client
|       +-- rsa_keys.go          # Gestion cles RSA + KMS
|       +-- organization.go      # Logique multi-tenant
|       +-- stripe_integration.go # Integration Stripe
|       +-- ...
+-- pkg/
|   +-- crypto/crypto.go         # AES-256-GCM, KMS wrapping
|   +-- kms/                     # KMS provider abstraction
|   +-- logging/logging.go       # Setup slog (JSON/text)
|   +-- metrics/metrics.go       # Definitions Prometheus
|   +-- ovh/                     # Client OVH (storage provisioning)
|   +-- secretsloader/           # Chargement secrets
|   +-- storage/s3.go            # Client S3 (upload, download, streaming)
+-- migrations/                  # 26 migrations SQL (up/down)
+-- Dockerfile                   # Build multi-stage Go

WebGUI Backend (Python)

Langage et frameworks

TechnologieVersionUsage
Python3.11+Langage
FastAPI0.100+Framework API async
asyncpglatestDriver PostgreSQL async
httpxlatestClient HTTP async
ovh1.2.0Client API OVH (billing)
resendlatestAPI d'envoi d'emails

Structure du projet Python

filesecure-webgui/backend/
+-- server.py                    # Point d'entree FastAPI
+-- config.py                    # Configuration
+-- db_postgres.py               # Connexion PostgreSQL
+-- email_service.py             # 6 templates email HTML
+-- models.py                    # Modeles Pydantic
+-- routes/                      # 26 modules de routes
|   +-- auth.py                  # Authentification proxy
|   +-- share.py                 # Share links proxy
|   +-- transfers.py             # Transferts
|   +-- admin_dashboard.py       # Dashboard superadmin
|   +-- sso.py                   # SSO Zitadel (OIDC)
|   +-- audit.py                 # Audit logs
|   +-- ...
+-- services/
|   +-- ovh_billing.py           # Facturation OVH S3
+-- utils/
|   +-- audit.py                 # Logger d'audit
|   +-- scheduler.py             # Collecte S3 periodique
+-- migrations/                  # Migrations WebGUI

Frontend React

Langage et frameworks

TechnologieVersionUsage
React18Framework UI
React Routerv6Routing
Tailwind CSS3Styling
shadcn/uilatestComposants UI
RechartslatestGraphiques
AxioslatestClient HTTP
TinyMCElatestEditeur de texte enrichi
Stripe.jslatestElements de paiement

Structure du projet React

filesecure-webgui/frontend/src/
+-- App.js                       # Routes principales
+-- contexts/
|   +-- AuthContext.jsx           # Authentification (JWT)
|   +-- EncryptionContext.jsx     # Chiffrement cote client
|   +-- LanguageContext.jsx       # Internationalisation
|   +-- StripeContext.jsx         # Integration Stripe Elements
+-- pages/
|   +-- DashboardPage.jsx         # Dashboard (share links, metriques)
|   +-- FilesPage.jsx             # Gestionnaire de fichiers
|   +-- ShareLinkPage.jsx         # Page publique share link
|   +-- TransferPage.jsx          # Page publique transfert
|   +-- UsersPage.jsx             # Gestion utilisateurs
|   +-- SubscriptionPage.jsx      # Gestion abonnement
|   +-- AuditLogsPage.jsx         # Logs d'audit
|   +-- admin/                    # Pages d'administration
|   +-- public/                   # Pages marketing publiques
+-- components/
|   +-- StorageDashboard.jsx      # Dashboard S3 superadmin
|   +-- CreateTransferDialog.jsx  # Dialog creation transfert
|   +-- EncryptedUploadDialog.jsx # Upload chiffre
|   +-- Sidebar.jsx               # Navigation laterale
|   +-- ...

On this page