Comparer les révisions

Auteur SHA1 Message Date

2026-10-31

Théo GastineletClaude Opus 5.5 5ceed17620 beta : essayer chaque cookie jrb_s reçu (ancien cookie qui masquait la session)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 14:37:56 +01:00
Théo GastineletClaude Opus 5.5 3645a80139 beta : sessions.code_id peut être NULL (inscription libre cassée sur les anciennes bases)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 13:11:18 +01:00
Théo GastineletClaude Opus 5.5 1228bf47aa fix(beta): API admin limitee a admin.jobrunner.fr, effacement et purge des testeurs, plafonds des captures, deconnexion en POST
- X-Admin seul ne suffit plus : Host doit etre admin.jobrunner.fr (le vhost public transmet les en-tetes du visiteur)
- feedback.tester_id : retours lies au testeur, effaces avec lui (captures comprises)
- codes.py effacer-testeur / purger (simulation par defaut)
- captures : 30/jour/auteur, 500 Mo au total, 5 Go libres minimum
- /__beta/logout en POST avec X-Beta (F5)
- 5 tests ajoutes (30 au total)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-31 11:45:45 +01:00

2026-10-30

Théo Gastinel 7148f3d04b docs: mise a jour du tableau des fonctionnalites (inscription libre & gestion testeurs) 2026-10-30 19:16:09 +01:00
Théo Gastinel 66e2988a14 feat(beta): inscription libre avec acces immediat, conservation IP 13 mois LCEN et gestion testeurs 2026-10-30 19:13:25 +01:00

2026-10-29

Théo Gastinel 6dc0f6c296 feat(admin): suivi des candidatures recues, suppression de code et compteur d utilisations 2026-10-29 15:44:47 +01:00
Théo Gastinel 3420ebee3d fix(social): mise a jour du lien Instagram officiel vers @jobrunner_france 2026-10-29 15:36:55 +01:00
Théo Gastinel 57fb12c8f7 docs: mise a jour de la documentation technique et du plan de deploiement en production 2026-10-29 12:47:58 +01:00
Théo Gastinel d4a2b7fa15 feat(admin): ajout du générateur de codes d'accès bêta dans l'espace projet 2026-10-29 12:40:39 +01:00
Théo Gastinel 2034610335 feat(beta): formulaire et gate autonomes, deploiement dns 2026-10-29 11:56:34 +01:00
Théo GastineletClaude Sonnet 5.5 7e23443f1b fix(beta): deni de service, concurrence par IP, delai total, pas de keep-alive, exposition derriere Caddy
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:31:40 +01:00
Théo GastineletClaude Sonnet 5.5 15da7e1385 fix(beta): formulaire PDF sur 2 pages (la signature depassait de la page)
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:30:35 +01:00
Théo GastineletClaude Sonnet 5.5 c3829a3848 feat(beta): bandeau, avis, bots, formulaire testeur (web + PDF AcroForm), plan de deploiement
Bandeau Beta, bouton Donner mon avis (texte + capture), libelles SIMULE, fusion des donnees de demo
(bots), formulaire web et PDF a la charte, plan de deploiement non applique.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:29:44 +01:00
Théo GastineletClaude Sonnet 5.5 914f422893 fix(beta): limite de tentatives atomique, corps borne par route, plafond de connexions
Tentative en attente enregistree avant verification, semaphore sur /enter, limites 2000/8000 o avant authentification, feedback apres session, delai total de lecture 10 s, 64 connexions max.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:29:20 +01:00
Théo GastineletClaude Sonnet 5.5 13910d8cfb fix(beta): lecture du corps hors verrou, delai global sans blocage
Corps lu avant la base, verrou limite aux appels SQL, timeout 10 s ; le compteur global d echecs n ajoute qu un delai (un code valide passe toujours) ; injection avant le DERNIER body.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:27:40 +01:00
Théo GastineletClaude Sonnet 5.5 3649917f23 fix(beta): serveur a porte d entree, traversee de chemin refusee
Segments . et .. (bruts ou encodes) refuses avant routage ; polices depuis un dossier fixe, logos en liste blanche ; tests de traversee.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:25:51 +01:00
Théo GastineletClaude Sonnet 5.5 1fffd39e5c fix(beta): neutralise les caracteres de controle dans les sorties terminal
co-authored below

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:23:57 +01:00
Théo GastineletClaude Sonnet 5.5 6a7872b09b feat(beta): stockage des codes d'acces (SQLite) avec droits restreints
Dossier de donnees en 0700, cle en 0600 (O_EXCL), CSV des codes en 0600,
umask 077 a l'ouverture de la base. Test des droits (ignore sous Windows).

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-29 10:22:08 +01:00
25 fichiers modifiés avec 6423 ajouts et 20 suppressions

Aucun fichier ne correspond à votre recherche

+6
Voir le fichier
@@ -30,3 +30,9 @@ WhatsApp Video*.mp4
*.caddy *.caddy
*auth* *auth*
*.secret *.secret
# Bêta testeurs : base locale, captures, codes émis (jamais dans git)
beta/data/
beta/pdf/*.ttf
__pycache__/
*.pyc
+30 -15
Voir le fichier
@@ -37,23 +37,32 @@ jobrunner web/
├── .gitignore # Protection des clés privées, logs et dépendances ├── .gitignore # Protection des clés privées, logs et dépendances
├── README.md # Présentation du dépôt ├── README.md # Présentation du dépôt
├── DOCUMENTATION.md # Présente documentation technique complète ├── DOCUMENTATION.md # Présente documentation technique complète
├── index.html # Espace projet : tableau de bord (point d'entrée ; accès protégé par Caddy basic_auth) ├── index.html # Espace projet : tableau de bord & générateur de codes bêta (admin.jobrunner.fr)
├── app.html # Application Web frontend complète (HTML, CSS inline, JS vanilla) ├── app.html # Application Web frontend complète (HTML, CSS inline, JS vanilla)
├── charte.html # Charte graphique v1.1 (couleurs, typo, logo, icônes, animations) ├── charte.html # Charte graphique v1.1 (couleurs, typo, logo, icônes, animations)
├── legal.html # Documents légaux (CGU, CGV, confidentialité, cookies, mentions) — brouillon, voir docs/conformite-legale.md ├── legal.html # Documents légaux (CGU, CGV, confidentialité, cookies, mentions) — brouillon
├── package.json # Outil de build CSS (devDependency : Tailwind 3.4.19) ├── package.json # Outil de build CSS (devDependency : Tailwind 3.4.19)
├── tailwind.config.js # Palette et ombres du site (source du CSS généré, lit app.html) ├── tailwind.config.js # Palette et ombres du site (source du CSS généré, lit app.html)
├── beta/ # Couche autonome de la bêta testeurs (Python 3 standard)
│ ├── server.py # Serveur HTTP (porte d'entrée, sessions, API admin, injection CSS/JS)
│ ├── codes.py # CLI d'administration des codes d'accès (génération, révocation, liste)
│ ├── db.py # Couche SQLite (codes, sessions, tentatives, audit, démo)
│ ├── bots.py # Simulation d'activité lente et profils fictifs
│ ├── static/ # Pages HTML autonomes (formulaire.html, gate.html)
│ ├── pdf/ # Générateur du formulaire d'engagement testeur PDF (AcroForm)
│ ├── deploiement/ # Architecture et plan de déploiement en production (PLAN.md)
│ └── tests/ # Suite de 25 tests unitaires automatisés
└── assets/ └── assets/
├── css/ ├── css/
│ ├── app.css # CSS Tailwind compilé (généré, à versionner) │ ├── app.css # CSS Tailwind compilé (généré, à versionner)
│ ├── espace.css # Styles de l'espace projet (index.html) │ ├── espace.css # Styles de l'espace projet (index.html) dont zone gestion bêta
│ ├── legal.css # Styles de legal.html │ ├── legal.css # Styles de legal.html
│ ├── tailwind.src.css # Entrée du build Tailwind + règle reduced-motion │ ├── tailwind.src.css # Entrée du build Tailwind + règle reduced-motion
│ └── fonts.css # @font-face Plus Jakarta Sans et Outfit (auto-hébergées) │ └── fonts.css # @font-face Plus Jakarta Sans et Outfit (auto-hébergées)
├── js/ ├── js/
│ └── legal.js # Navigation de legal.html │ └── legal.js # Navigation de legal.html
├── icones-jobrunner/ # 15 icônes de la charte (SVG, currentColor, sans cadre) ├── icones-jobrunner/ # 15 icônes de la charte (SVG, currentColor, sans cadre)
├── img/logo-j.svg # Logo J de la charte v1.1 (l'ancien logo-light.svg reste utilisé par app.html) ├── img/logo-j.svg # Logo J de la charte v1.1
├── fonts/ # Fichiers .woff2 Plus Jakarta Sans et Outfit (latin + latin-ext) ├── fonts/ # Fichiers .woff2 Plus Jakarta Sans et Outfit (latin + latin-ext)
└── icons/ └── icons/
├── phosphor.css # Icônes Phosphor (sous-ensemble utilisé) ├── phosphor.css # Icônes Phosphor (sous-ensemble utilisé)
@@ -116,6 +125,8 @@ Le fichier `index.html` intègre déjà les modules complets suivants :
| **Processus de Séquestre Mock** | Modale de paiement avec explication des fonds protégés et validation de fin de mission. | | **Processus de Séquestre Mock** | Modale de paiement avec explication des fonds protégés et validation de fin de mission. |
| **Espace Profil & Annonces** | Gestion des annonces personnelles, favoris, historique et statut de certification. | | **Espace Profil & Annonces** | Gestion des annonces personnelles, favoris, historique et statut de certification. |
| **Footer & Mentions Légales** | Modales légales (Mentions légales, CGU, Politique de confidentialité RGPD, Cookies). | | **Footer & Mentions Légales** | Modales légales (Mentions légales, CGU, Politique de confidentialité RGPD, Cookies). |
| **Inscription Libre & Bêta (`jobrunner.fr`)** | Inscription directe via formulaire autonome (`/__beta/formulaire`), accès immédiat sans code requis, conservation des adresses IP pendant 13 mois (décret n° 2021-1362 / LCEN), bandeau testeur et retours d'expérience. |
| **Gestionnaire Bêta (`admin.jobrunner.fr`)** | Suivi en temps réel des testeurs inscrits, affichage des adresses IP et dates de purge légale 13 mois, suspension/réactivation des accès, et outil d'émission de codes d'exception. |
--- ---
@@ -144,19 +155,23 @@ Le fichier `index.html` intègre déjà les modules complets suivants :
--- ---
## 6. Mise en Ligne & Configuration du Domaine `Jobrunner.fr` ## 6. Mise en Ligne & Architecture de Production (Déployé le 29/10/2026)
### Pointage DNS du domaine : L'infrastructure sépare le site public de test et l'espace projet / administration :
Dans l'interface de gestion de votre nom de domaine `Jobrunner.fr` (chez votre registrar) :
* **Enregistrement `A` :** ### 6.1 Domaines & DNS (Infomaniak)
* Hôte : `@` * `jobrunner.fr`, `www.jobrunner.fr`, `beta.jobrunner.fr` : Enregistrements `A` vers `179.237.102.233` (VPS Suisse).
* Valeur : `IP_DE_VOTRE_SERVEUR` * `admin.jobrunner.fr` : Enregistrement `A` vers `179.237.102.233` (Espace projet sous authentification HTTP Basic Auth).
* **Enregistrement `CNAME` :**
* Hôte : `www` ### 6.2 Architecture Caddy (VPS `cornafsuisse`)
* Valeur : `jobrunner.fr.` * **`admin.jobrunner.fr`** : Protégé par HTTP Basic Auth (`/etc/caddy/jobrunner-auth.caddy`). Sert les fichiers statiques de `/srv/jobrunner.fr`. La route `/_admin/api/*` est proxifiée vers `10.88.88.2:8830` via WireGuard (`wg2`) avec l'en-tête interne `X-Admin: 1`.
* **Certificat SSL / HTTPS :** * **`jobrunner.fr` (et alias `www`, `beta`)** : Proxifié vers `10.88.88.2:8830` via WireGuard (`wg2`).
* Activation du certificat HTTPS Let's Encrypt (gratuit) sur votre serveur pour un affichage sécurisé avec le cadenas vert.
### 6.3 Serveur Backend (`cornafserver`)
* **Service** : `jobrunner-beta.service` (systemd utilisateur).
* **Port** : `8830`, sécurisé par `nftables` (accessible uniquement depuis le VPS via WireGuard `wg2`).
* **Données** : `/home/cornaf2049/jobrunner-beta-data/beta.sqlite` avec permissions restreintes (`0600`).
* **Sécurité applicative** : HMAC-SHA256 pour les codes d'accès, anti-bruteforce (6 essais / 15 min), plafonds de requêtes concurrentes, timeouts stricts de 20 s.
--- ---
+4 -4
Voir le fichier
@@ -2120,7 +2120,7 @@
// ================= CONFIGURATION & CONSTANTES GLOBALES ================= // ================= CONFIGURATION & CONSTANTES GLOBALES =================
const ENABLE_SHORTS = true; const ENABLE_SHORTS = true;
const SOCIAL_LINKS = { const SOCIAL_LINKS = {
instagram: 'https://www.instagram.com/jobrunnerr/', instagram: 'https://www.instagram.com/jobrunner_france/',
whatsapp: '#', whatsapp: '#',
discord: '#' discord: '#'
}; };
@@ -6456,8 +6456,8 @@
function handleInstagramClick(e) { function handleInstagramClick(e) {
e.preventDefault(); e.preventDefault();
const webUrl = SOCIAL_LINKS.instagram || 'https://www.instagram.com/jobrunnerr/'; const webUrl = SOCIAL_LINKS.instagram || 'https://www.instagram.com/jobrunner_france/';
const appUrl = 'instagram://user?username=jobrunnerr'; const appUrl = 'instagram://user?username=jobrunner_france';
// Tente d'ouvrir directement l'application Instagram native (iOS/Android) // Tente d'ouvrir directement l'application Instagram native (iOS/Android)
// Si pas installée ou sur PC, bascule naturellement sur l'URL web dans un nouvel onglet // Si pas installée ou sur PC, bascule naturellement sur l'URL web dans un nouvel onglet
@@ -6698,7 +6698,7 @@
</div> </div>
<div class="flex-grow min-w-0"> <div class="flex-grow min-w-0">
<span class="block text-white group-hover:text-[#E4405F] transition-colors font-bold leading-none">Instagram</span> <span class="block text-white group-hover:text-[#E4405F] transition-colors font-bold leading-none">Instagram</span>
<span class="block text-[9px] text-gray-400">@jobrunnerr</span> <span class="block text-[9px] text-gray-400">@jobrunner_france</span>
</div> </div>
<i class="ph-bold ph-arrow-up-right text-gray-400 group-hover:text-white text-[10px]"></i> <i class="ph-bold ph-arrow-up-right text-gray-400 group-hover:text-white text-[10px]"></i>
</a> </a>
+489
Voir le fichier
@@ -50,3 +50,492 @@ a.tuile:hover .fleche{transform:translateX(4px)}
section+section{margin-top:44px} section+section{margin-top:44px}
footer{max-width:1080px;margin:0 auto;padding:0 16px 32px;color:var(--doux);font-size:13px} footer{max-width:1080px;margin:0 auto;padding:0 16px 32px;color:var(--doux);font-size:13px}
@media (prefers-reduced-motion:reduce){*{transition:none!important}} @media (prefers-reduced-motion:reduce){*{transition:none!important}}
/* ================= GESTION DE LA BÊTA ================= */
.beta-zone {
margin-top: 44px;
}
.beta-zone-entete {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 16px;
flex-wrap: wrap;
gap: 12px;
}
.beta-zone-entete h2 {
margin: 0;
}
.lien-externe {
font-size: 13.5px;
font-weight: 600;
color: var(--sauge);
display: inline-flex;
align-items: center;
gap: 4px;
}
.lien-externe:hover {
text-decoration: underline;
}
.carte-gestion-beta {
background: var(--carte);
border: 1.5px solid var(--filet);
border-radius: 24px;
padding: 28px;
box-shadow: 0 10px 30px -15px rgba(45, 45, 45, 0.08);
}
.generateur-desc {
margin-bottom: 22px;
}
.generateur-desc h3 {
font-size: 20px;
font-weight: 700;
margin: 0 0 6px;
color: var(--texte);
}
.generateur-desc p {
color: var(--doux);
font-size: 14.5px;
margin: 0;
line-height: 1.5;
}
.generateur-desc code {
font-family: monospace;
font-size: 13.5px;
background: #FFFFFF;
padding: 2px 6px;
border-radius: 6px;
border: 1px solid var(--filet);
}
.form-generateur {
margin-bottom: 24px;
}
.ligne-form {
display: grid;
grid-template-columns: 2fr 1fr auto;
gap: 14px;
align-items: flex-end;
}
@media (max-width: 760px) {
.ligne-form {
grid-template-columns: 1fr;
gap: 12px;
}
}
.champ {
display: flex;
flex-direction: column;
gap: 6px;
}
.champ label {
font-size: 13px;
font-weight: 700;
color: var(--texte);
}
.champ input, .champ select {
font-family: inherit;
font-size: 15px;
padding: 12px 16px;
border: 1.5px solid var(--filet);
border-radius: 12px;
background: #FFFFFF;
color: var(--texte);
outline: none;
transition: all 0.2s ease;
}
.champ input:focus, .champ select:focus {
border-color: var(--sauge);
box-shadow: 0 0 0 3px rgba(139, 158, 144, 0.2);
}
.btn-creer {
font-family: inherit;
font-size: 15px;
font-weight: 700;
background: var(--sauge);
color: #FFFFFF;
border: none;
border-radius: 999px;
padding: 13px 26px;
cursor: pointer;
display: inline-flex;
align-items: center;
justify-content: center;
gap: 8px;
transition: all 0.2s ease;
white-space: nowrap;
height: 48px;
}
.btn-creer:hover {
background: #6E8173;
transform: translateY(-1px);
}
.btn-creer:disabled {
opacity: 0.6;
cursor: wait;
transform: none;
}
.alerte-erreur {
background: #FDF2F0;
color: #A0554B;
border: 1px solid #F5D6D1;
padding: 10px 14px;
border-radius: 10px;
font-size: 13.5px;
font-weight: 600;
margin-top: 12px;
}
/* Zone résultat nouveau code */
.zone-nouveau-code {
background: #EBF0EC;
border: 1.5px solid #D8E0DA;
border-radius: 18px;
padding: 22px;
margin: 24px 0;
animation: apparaitre 0.3s ease;
}
@keyframes apparaitre {
from { opacity: 0; transform: translateY(6px); }
to { opacity: 1; transform: translateY(0); }
}
.nouveau-code-entete {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 12px;
flex-wrap: wrap;
gap: 8px;
}
.badge-succes {
display: inline-flex;
align-items: center;
gap: 6px;
font-size: 12.5px;
font-weight: 700;
color: #4A6E52;
text-transform: uppercase;
letter-spacing: 0.05em;
}
.label-testeur {
font-size: 13.5px;
font-weight: 700;
color: var(--texte);
}
.code-valeur-ligne {
display: flex;
align-items: center;
gap: 14px;
margin-bottom: 18px;
flex-wrap: wrap;
}
.code-gros {
font-family: monospace;
font-size: clamp(20px, 4vw, 26px);
font-weight: 800;
letter-spacing: 0.08em;
color: var(--texte);
background: #FFFFFF;
padding: 8px 18px;
border-radius: 12px;
border: 1.5px solid #D8E0DA;
}
.btn-copier {
font-family: inherit;
font-size: 14px;
font-weight: 700;
background: #FFFFFF;
color: var(--texte);
border: 1.5px solid var(--filet);
border-radius: 999px;
padding: 10px 18px;
cursor: pointer;
transition: all 0.2s ease;
}
.btn-copier:hover {
border-color: var(--sauge);
color: var(--sauge);
}
.whatsapp-partage {
background: #FFFFFF;
border: 1.5px solid #D8E0DA;
border-radius: 14px;
padding: 14px 16px;
}
.whatsapp-partage-titre {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 8px;
font-size: 13px;
font-weight: 700;
color: var(--texte);
flex-wrap: wrap;
gap: 8px;
}
.btn-copier-petit {
font-family: inherit;
font-size: 12px;
font-weight: 700;
background: var(--fond);
border: 1px solid var(--filet);
border-radius: 999px;
padding: 4px 12px;
cursor: pointer;
color: var(--texte);
transition: all 0.2s ease;
}
.btn-copier-petit:hover {
background: var(--sauge);
color: #FFFFFF;
border-color: var(--sauge);
}
.whatsapp-champ {
width: 100%;
font-family: inherit;
font-size: 13px;
line-height: 1.45;
color: var(--doux);
background: var(--fond);
border: 1px solid var(--filet);
border-radius: 8px;
padding: 8px 10px;
resize: vertical;
box-sizing: border-box;
}
/* Tableau historique */
.historique-codes {
margin-top: 28px;
border-top: 1px solid var(--filet);
padding-top: 20px;
}
.liste-codes-entete {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 12px;
}
.liste-codes-entete h4 {
margin: 0;
font-size: 15px;
font-weight: 700;
color: var(--texte);
}
.btn-rafraichir {
font-family: inherit;
font-size: 12.5px;
font-weight: 600;
background: none;
border: 1px solid var(--filet);
border-radius: 999px;
padding: 4px 12px;
cursor: pointer;
color: var(--doux);
}
.btn-rafraichir:hover {
color: var(--texte);
border-color: var(--texte);
}
.tableau-scroll {
overflow-x: auto;
}
.table-codes {
width: 100%;
border-collapse: collapse;
font-size: 13.5px;
text-align: left;
}
.table-codes th {
font-weight: 700;
color: var(--doux);
padding: 8px 12px;
border-bottom: 1.5px solid var(--filet);
font-size: 12px;
text-transform: uppercase;
letter-spacing: 0.05em;
}
.table-codes td {
padding: 12px;
border-bottom: 1px solid var(--filet);
color: var(--texte);
}
.table-codes tr:last-child td {
border-bottom: none;
}
.badge-statut {
display: inline-flex;
align-items: center;
gap: 5px;
font-size: 11.5px;
font-weight: 700;
padding: 3px 9px;
border-radius: 999px;
text-transform: uppercase;
}
.badge-statut.actif { background: #D8E0DA; color: #3E5A44; }
.badge-statut.expire { background: #EAE8E2; color: #7A7A7A; }
.badge-statut.revoque { background: #F5D6D1; color: #A0554B; }
.chargement {
color: var(--doux);
font-size: 13.5px;
padding: 12px 0;
margin: 0;
}
/* Badges d'utilisations & actions */
.badge-usages {
display: inline-block;
font-size: 12px;
font-weight: 700;
padding: 3px 8px;
border-radius: 6px;
background: var(--filet);
color: var(--texte);
}
.badge-usages.actif {
background: #D8E0DA;
color: #2F4D35;
}
.date-derniere {
display: block;
font-size: 11px;
color: var(--doux);
margin-top: 3px;
}
.btn-action-suppr {
font-family: inherit;
font-size: 12px;
font-weight: 600;
background: transparent;
color: #A0554B;
border: 1px solid #F5D6D1;
padding: 4px 10px;
border-radius: 6px;
cursor: pointer;
transition: all 0.2s ease;
}
.btn-action-suppr:hover {
background: #A0554B;
color: #FFFFFF;
border-color: #A0554B;
}
/* Bloc Candidatures */
.candidatures-bloc {
margin-top: 32px;
border-top: 1.5px solid var(--filet);
padding-top: 24px;
}
.btn-remplir-code {
font-family: inherit;
font-size: 12px;
font-weight: 700;
background: var(--sauge);
color: #FFFFFF;
border: none;
border-radius: 999px;
padding: 5px 12px;
cursor: pointer;
display: inline-flex;
align-items: center;
gap: 4px;
transition: all 0.2s ease;
white-space: nowrap;
}
.btn-remplir-code:hover {
background: #6E8173;
}
.contact-ligne {
font-size: 12.5px;
display: flex;
flex-direction: column;
gap: 2px;
}
.contact-ligne a {
color: var(--texte);
text-decoration: underline;
text-underline-offset: 2px;
}
.contact-ligne a:hover {
color: var(--sauge);
}
.badge-age {
display: inline-block;
font-size: 11px;
font-weight: 700;
padding: 2px 7px;
border-radius: 4px;
background: #EAE8E2;
color: var(--texte);
margin-left: 6px;
}
.badge-age.mineur {
background: #F8E3D8;
color: #8C4824;
}
.parent-info {
display: block;
font-size: 11px;
color: #8C4824;
margin-top: 2px;
}
/* Styles pour la gestion des testeurs et IP 13 mois */
.badge-ip {
font-family: monospace;
font-size: 12px;
background: #FFFFFF;
border: 1px solid var(--filet);
padding: 3px 7px;
border-radius: 6px;
color: var(--texte);
display: inline-block;
}
.ip-purge-info {
display: block;
font-size: 10.5px;
color: var(--doux);
margin-top: 2px;
}
.btn-action-toggle {
font-family: inherit;
font-size: 11.5px;
font-weight: 700;
border-radius: 6px;
padding: 4px 10px;
cursor: pointer;
transition: all 0.2s ease;
border: 1px solid transparent;
}
.btn-action-toggle.suspendre {
background: #FFF4E5;
color: #B25E00;
border-color: #FFE2B8;
}
.btn-action-toggle.suspendre:hover {
background: #B25E00;
color: #FFFFFF;
}
.btn-action-toggle.reactiver {
background: #EBF5EE;
color: #2F663C;
border-color: #CFE8D7;
}
.btn-action-toggle.reactiver:hover {
background: #2F663C;
color: #FFFFFF;
}
.actions-cell {
display: flex;
align-items: center;
gap: 6px;
flex-wrap: wrap;
}
.bloc-secondaire {
margin-top: 36px;
border-top: 1.5px dashed var(--filet);
padding-top: 24px;
}
+42
Voir le fichier
@@ -0,0 +1,42 @@
# Bêta testeurs JobRunner
Couche autonome, sans dépendance externe (Python 3 standard), qui sert le site JobRunner derrière un code d'accès sécurisé et offre une interface d'inscription pour les testeurs.
Le site d'origine n'est pas altéré : le serveur injecte `beta.js` et `beta.css` dans les pages servies aux testeurs.
## Architecture & Déploiement en production (depuis le 29/10/2026)
- **Domaine public bêta** : `https://jobrunner.fr` (et `www.jobrunner.fr`, `beta.jobrunner.fr`)
- Redirige automatiquement vers la porte d'entrée `/__beta/gate`.
- Formulaire interactif autonome d'inscription : `https://jobrunner.fr/__beta/formulaire`.
- Proxifié par le Caddy du VPS (`cornafsuisse`) vers le port 8830 de `cornafserver` via WireGuard (`wg2`).
- **Espace projet & Administration** : `https://admin.jobrunner.fr`
- Protégé par HTTP Basic Auth au niveau de Caddy (`/etc/caddy/jobrunner-auth.caddy`).
- Sert les maquettes et l'espace projet (`/srv/jobrunner.fr`).
- Intègre la **Gestion de la Bêta** pour générer en un clic des codes d'accès uniques (`JRB-XXXX-XXXX-XXXX`), copier le message d'invitation pré-rédigé pour WhatsApp/SMS, et suivre l'historique des codes.
- Route API : `/_admin/api/*` proxifiée vers `cornafserver:8830` avec l'en-tête interne `X-Admin: 1`.
## Commandes locales & Développement
```bash
set BETA_DATA=...\data # optionnel (défaut : beta/data, ignoré par git)
python beta/codes.py generer --label "Prénom N." --jours 30
python beta/server.py # http://127.0.0.1:8830/
python beta/bots.py # bots lents (autre terminal)
python -m unittest discover -s beta/tests -p "test_*.py"
python beta/pdf/generer_formulaire.py # régénère le PDF d'engagement (reportlab, fonttools, brotli)
```
## Sécurité & Robustesse
- **Codes d'accès** : Hachage HMAC-SHA256 avec sel local (`salt` de 32 octets sous `0600`), comparaison en temps constant `hmac.compare_digest`.
- **Anti-bruteforce** : Limite stricte de 6 tentatives par IP par tranche de 15 minutes, temporisation adaptative.
- **Déni de service & DoS** :
- Plafond de 64 connexions simultanées, max 2 requêtes `/enter` concurrentes par IP.
- Timeout total de 20 s (ligne de requête + en-têtes + corps).
- Taille de corps bornée par route (ex. 2 ko pour `/enter`, 4 ko pour `/admin/api/codes/creer`).
- Aucun keep-alive (`Connection: close` systématique).
- **Protection des données** :
- Base SQLite dédiée (`beta.sqlite`) avec permissions `0600` (dossier parent en `0700`).
- Tables de démo isolées (`demo_*`) réinitialisables via `bots.py --reset`.
- CSP stricte : `connect-src 'self'`, `frame-ancestors 'none'`, pas d'accès sortant vers des prestataires tiers de paiement.
- Respect RGPD : données testeurs conservées uniquement pour la durée du test, purgeable après clôture.
+144
Voir le fichier
@@ -0,0 +1,144 @@
"""Bots de la bêta JobRunner : profils FICTIFS qui simulent des annonces, des
messages et des réservations à rythme lent, pour que les testeurs voient de la vie.
python beta/bots.py # tourne en continu (une action toutes les 45 à 120 s)
python beta/bots.py --once 20 --vite # 20 actions sans pause (tests)
python beta/bots.py --reset # efface UNIQUEMENT les données de démo (tables demo_*)
Garde-fous : tout est écrit dans les tables demo_* de la base de la bêta ; chaque
profil porte la mention « profil fictif » ; les montants sont « SIMULÉ » ; aucune
adresse e-mail, aucun numéro, aucun appel réseau, aucune vraie personne.
"""
import argparse
import random
import sys
import time
from pathlib import Path
sys.path.insert(0, str(Path(__file__).resolve().parent))
import db # noqa: E402
PRENOMS = ["Léa", "Karim", "Inès", "Hugo", "Camille", "Yanis", "Manon", "Théa", "Nolan", "Sofia", "Malo", "Ayla"]
INITIALES = "BCDFGHJKLMNPRSTV"
VILLES = [("Grenoble", "38", "Auvergne-Rhône-Alpes"), ("Lyon", "69", "Auvergne-Rhône-Alpes"),
("Lille", "59", "Hauts-de-France"), ("Nantes", "44", "Pays de la Loire"),
("Toulouse", "31", "Occitanie"), ("Rennes", "35", "Bretagne"), ("Strasbourg", "67", "Grand Est")]
ANNONCES = { # catégorie (ids de l'app) : (titre, prix, unité)
"brico": [("Montage de meubles en kit", 35, "h"), ("Petites réparations à domicile", 30, "h")],
"jardin": [("Tonte et taille de haies", 28, "h"), ("Entretien de jardin", 32, "h")],
"menage": [("Ménage appartement 2 pièces", 22, "h"), ("Repassage à domicile", 20, "h")],
"cours": [("Soutien maths collège-lycée", 25, "h"), ("Cours d'anglais conversation", 24, "h")],
"info": [("Dépannage ordinateur et box", 40, "h"), ("Installation imprimante et wifi", 35, "h")],
"trans": [("Aide au déménagement (camion fourni)", 120, "forfait"), ("Transport de meubles", 60, "forfait")],
}
MSG_BOT = ["Bonjour ! Je suis disponible cette semaine, qu'est-ce qui vous arrangerait ?",
"Merci pour votre message. Pouvez-vous me donner l'adresse approximative et le créneau souhaité ?",
"J'ai de quoi m'en occuper ce week-end. Je vous envoie une proposition.",
"Petite précision : j'apporte mon propre matériel, pas besoin de vous en occuper.",
"Rappel : tout ceci est un échange de démonstration entre un testeur et un bot."]
MENTION = "Profil fictif créé par un bot de test de la bêta JobRunner. Aucune vraie personne."
def reset(c):
for t in ("demo_activity", "demo_msgs", "demo_convs", "demo_ads", "demo_profiles"):
c.execute(f"DELETE FROM {t}")
c.commit()
def nb(c, t):
return c.execute(f"SELECT COUNT(*) FROM {t}").fetchone()[0]
def activite(c, kind, texte):
c.execute("INSERT INTO demo_activity(created_at,kind,text) VALUES(?,?,?)", (time.time(), kind, texte))
def nouveau_profil(c, rnd):
prenom = rnd.choice(PRENOMS)
ville = rnd.choice(VILLES)
seed = f"{prenom}{rnd.randint(100, 999)}"
cur = c.execute("INSERT INTO demo_profiles(created_at,first,last_initial,city,dept,region,seed,bio) VALUES(?,?,?,?,?,?,?,?)",
(time.time(), prenom, rnd.choice(INITIALES), ville[0], ville[1], ville[2], seed, MENTION))
p = c.execute("SELECT * FROM demo_profiles WHERE id=?", (cur.lastrowid,)).fetchone()
activite(c, "profil", f"{p['first']} {p['last_initial']}. (bot) rejoint JobRunner à {p['city']}")
def action(c, rnd):
now = time.time()
profils = [r["id"] for r in c.execute("SELECT id FROM demo_profiles")]
if len(profils) < 4:
nouveau_profil(c, rnd)
c.commit()
return "profil"
choix = rnd.choices(["profil", "annonce", "message", "conv", "reservation"], [1, 4, 4, 2, 3])[0]
if choix == "profil" and len(profils) >= 12:
choix = "annonce"
if choix == "annonce" and nb(c, "demo_ads") >= 24:
choix = "message"
if choix == "conv" and nb(c, "demo_convs") >= 6:
choix = "message"
if choix == "profil":
nouveau_profil(c, rnd)
elif choix == "annonce":
pid = rnd.choice(profils)
cat = rnd.choice(list(ANNONCES))
titre, prix, unite = rnd.choice(ANNONCES[cat])
c.execute("INSERT INTO demo_ads(created_at,profile_id,category,title,price,unit,descr) VALUES(?,?,?,?,?,?,?)",
(now, pid, cat, titre, prix + rnd.choice([-5, 0, 0, 5]), unite, MENTION))
activite(c, "annonce", f"Nouvelle annonce (bot) : {titre}")
elif choix == "conv":
pid = rnd.choice(profils)
cat = rnd.choice(list(ANNONCES))
titre, prix, _ = rnd.choice(ANNONCES[cat])
cur = c.execute("INSERT INTO demo_convs(created_at,profile_id,title,amount,status) VALUES(?,?,?,?,?)",
(now, pid, titre, prix * 2, rnd.choice(["none", "proposed"])))
c.execute("INSERT INTO demo_msgs(created_at,conv_id,sender,text) VALUES(?,?,?,?)", (now, cur.lastrowid, "them", MSG_BOT[0]))
activite(c, "message", "Un bot a écrit à un testeur")
elif choix == "message":
convs = [r["id"] for r in c.execute("SELECT id FROM demo_convs")]
if convs:
cid = rnd.choice(convs)
if c.execute("SELECT COUNT(*) FROM demo_msgs WHERE conv_id=?", (cid,)).fetchone()[0] < 12:
c.execute("INSERT INTO demo_msgs(created_at,conv_id,sender,text) VALUES(?,?,?,?)",
(now, cid, "them", rnd.choice(MSG_BOT)))
activite(c, "message", "Nouveau message de bot")
elif choix == "reservation":
a, b = rnd.sample(profils, 2)
pa, pb = (c.execute("SELECT * FROM demo_profiles WHERE id=?", (x,)).fetchone() for x in (a, b))
etape = rnd.choice(["a réservé", "a validé la prestation de"])
activite(c, "reservation",
f"{pa['first']} {pa['last_initial']}. (bot) {etape} {pb['first']} {pb['last_initial']}. (bot) : "
f"{rnd.choice([30, 45, 60, 80, 120])} € SIMULÉ")
c.execute("DELETE FROM demo_activity WHERE id NOT IN (SELECT id FROM demo_activity ORDER BY id DESC LIMIT 60)")
c.commit()
return choix
def main(argv=None):
ap = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)
ap.add_argument("--reset", action="store_true")
ap.add_argument("--once", type=int, default=0, help="nombre d'actions puis sortie")
ap.add_argument("--vite", action="store_true", help="pas de pause entre actions (tests)")
ap.add_argument("--min", type=int, default=45)
ap.add_argument("--max", type=int, default=120)
ap.add_argument("--seed", type=int, default=None)
a = ap.parse_args(argv)
c = db.connect()
rnd = random.Random(a.seed)
if a.reset:
reset(c)
print("Données de démo effacées (tables demo_* uniquement).")
return
n = 0
while True:
print(time.strftime("%H:%M:%S"), action(c, rnd), flush=True)
n += 1
if a.once and n >= a.once:
break
if not a.vite:
time.sleep(rnd.randint(a.min, a.max))
if __name__ == "__main__":
main()
+136
Voir le fichier
@@ -0,0 +1,136 @@
"""Gestion des codes d'accès et des retours de la bêta (en ligne de commande, local).
python beta/codes.py generer --label "Prénom N." [--jours 30] [--nombre 1] [--sessions 3] [--csv]
python beta/codes.py liste
python beta/codes.py revoquer <id>
python beta/codes.py prolonger <id> --jours 14
python beta/codes.py journal [--n 30]
python beta/codes.py retours [--n 30]
python beta/codes.py testeurs
python beta/codes.py effacer-testeur <id> [--oui]
python beta/codes.py purger --avant AAAA-MM-JJ [--appliquer]
Le code en clair n'est affiché qu'une seule fois, à la génération.
"""
import argparse
import csv
import os
import sys
import time
import unicodedata
from datetime import datetime
from pathlib import Path
sys.path.insert(0, str(Path(__file__).resolve().parent))
import db # noqa: E402
def propre(v):
"""Remplace tout caractère de contrôle (catégorie Unicode C*) : un testeur ne doit
pas pouvoir injecter de séquence d'échappement dans le terminal."""
return "".join(" " if unicodedata.category(ch)[0] == "C" else ch for ch in str(v if v is not None else ""))
def fmt(ts):
return datetime.fromtimestamp(ts).strftime("%d/%m/%Y %H:%M") if ts else "-"
def etat(r):
if r["revoked_at"]:
return "révoqué"
if r["expires_at"] and r["expires_at"] <= time.time():
return "expiré"
return "actif"
def main(argv=None):
ap = argparse.ArgumentParser(description=__doc__, formatter_class=argparse.RawDescriptionHelpFormatter)
sp = ap.add_subparsers(dest="cmd", required=True)
g = sp.add_parser("generer")
g.add_argument("--label", required=True)
g.add_argument("--jours", type=int, default=30, help="durée de validité (0 = sans expiration)")
g.add_argument("--nombre", type=int, default=1)
g.add_argument("--sessions", type=int, default=3)
g.add_argument("--csv", action="store_true", help="écrit aussi beta/data/codes-emis.csv (hors git)")
sp.add_parser("liste")
r = sp.add_parser("revoquer"); r.add_argument("id", type=int)
p = sp.add_parser("prolonger"); p.add_argument("id", type=int); p.add_argument("--jours", type=int, required=True)
j = sp.add_parser("journal"); j.add_argument("--n", type=int, default=30)
f = sp.add_parser("retours"); f.add_argument("--n", type=int, default=30)
sp.add_parser("testeurs")
e = sp.add_parser("effacer-testeur"); e.add_argument("id", type=int); e.add_argument("--oui", action="store_true")
pu = sp.add_parser("purger"); pu.add_argument("--avant", required=True, help="AAAA-MM-JJ")
pu.add_argument("--appliquer", action="store_true", help="sans cette option : simulation seulement")
a = ap.parse_args(argv)
c = db.connect()
if a.cmd == "generer":
lignes = []
for i in range(a.nombre):
label = a.label if a.nombre == 1 else f"{a.label} {i + 1}"
cid, code = db.creer_code(c, label, a.jours, a.sessions)
lignes.append((cid, label, code))
print(f"#{cid} {propre(label)} {code}")
if a.csv:
f_ = db.DATA / "codes-emis.csv"
neuf = not f_.exists()
fd = os.open(f_, os.O_WRONLY | os.O_CREAT | os.O_APPEND, 0o600)
with os.fdopen(fd, "a", newline="", encoding="utf-8") as fh:
w = csv.writer(fh)
if neuf:
w.writerow(["id", "label", "code"])
w.writerows(lignes)
print(f"(écrit dans {f_} : hors git, à supprimer après envoi)")
elif a.cmd == "liste":
for r_ in c.execute("SELECT * FROM codes ORDER BY id"):
print(f"#{r_['id']:<3} {etat(r_):<8} {propre(r_['label']):<24} créé {fmt(r_['created_at'])} expire {fmt(r_['expires_at'])} "
f"usages {r_['uses']} dernier {fmt(r_['last_used_at'])}")
elif a.cmd == "revoquer":
c.execute("UPDATE codes SET revoked_at=? WHERE id=? AND revoked_at IS NULL", (time.time(), a.id))
c.execute("DELETE FROM sessions WHERE code_id=?", (a.id,))
c.commit()
db.journal(c, "code_revoque", a.id)
print(f"Code #{a.id} révoqué ; ses sessions sont coupées.")
elif a.cmd == "prolonger":
row = c.execute("SELECT * FROM codes WHERE id=?", (a.id,)).fetchone()
if not row or row["revoked_at"]:
sys.exit("Code introuvable ou révoqué.")
base = max(row["expires_at"] or time.time(), time.time())
c.execute("UPDATE codes SET expires_at=? WHERE id=?", (base + a.jours * 86400, a.id))
c.commit()
db.journal(c, "code_prolonge", a.id, None, f"+{a.jours} j")
print("Prolongé.")
elif a.cmd == "journal":
for r_ in c.execute("SELECT * FROM audit ORDER BY id DESC LIMIT ?", (a.n,)):
print(f"{fmt(r_['ts'])} {propre(r_['event']):<16} code={r_['code_id'] or '-'} ip={propre(r_['ip_hash']) or '-'} {propre(r_['detail'])}")
elif a.cmd == "retours":
for r_ in c.execute("SELECT f.*, c.label FROM feedback f LEFT JOIN codes c ON c.id=f.code_id ORDER BY f.id DESC LIMIT ?", (a.n,)):
print(f"#{r_['id']} {fmt(r_['ts'])} [{propre(r_['kind'])}] {propre(r_['label'])} sur {propre(r_['page'])} ({propre(r_['viewport'])})"
f"{' capture: ' + propre(r_['shot']) if r_['shot'] else ''}\n {propre(r_['text'])}")
elif a.cmd == "effacer-testeur":
row = c.execute("SELECT * FROM testers WHERE id=?", (a.id,)).fetchone()
if not row:
sys.exit("Testeur introuvable.")
if not a.oui:
sys.exit(f"Effacerait #{a.id} {propre(row['prenom'])} {propre(row['nom'])}, ses sessions, retours et captures. Relancer avec --oui.")
n = db.effacer_testeur(c, a.id)
db.journal(c, "testeur_supprime", None, None, f"id={a.id} retours={n} (cli)")
print(f"Testeur #{a.id} effacé ({n} retours).")
elif a.cmd == "purger":
try:
avant = datetime.strptime(a.avant, "%Y-%m-%d").timestamp()
except ValueError:
sys.exit("Date attendue : AAAA-MM-JJ")
bilan = db.purger(c, avant, simulation=not a.appliquer)
print(("PURGE APPLIQUÉE : " if a.appliquer else "Simulation (rien supprimé) : ") +
", ".join(f"{k} {v}" for k, v in bilan.items()))
elif a.cmd == "testeurs":
for r_ in c.execute("SELECT * FROM testers ORDER BY id"):
st = "ACTIF" if r_["actif"] else "SUSPENDU"
ip_str = f"IP={propre(r_['ip'])} (purge {fmt(r_['expire_ip_at'])})" if r_["ip"] else "IP: -"
print(f"#{r_['id']} [{st}] {propre(r_['prenom'])} {propre(r_['nom'])} <{propre(r_['email'])}> {propre(r_['tel'])} {ip_str} "
f"{'MINEUR (parent: ' + propre(r_['parent_nom']) + ')' if r_['mineur'] else 'majeur'} reseaux={r_['suivi_reseaux']}")
if __name__ == "__main__":
main()
+265
Voir le fichier
@@ -0,0 +1,265 @@
"""Stockage local de la bêta JobRunner (SQLite, un seul fichier hors git).
Tout ce qui est « démo » vit dans les tables demo_* : aucune vraie donnée
utilisateur n'existe dans ce dépôt, et la bêta n'a aucun lien avec une base
de production. Les codes d'accès ne sont jamais stockés en clair (hachés avec
un sel local).
"""
import hashlib
import hmac
import os
import secrets
import sqlite3
import time
from pathlib import Path
ICI = Path(__file__).resolve().parent
ALPHABET = "ABCDEFGHJKMNPQRSTUVWXYZ23456789" # sans I, L, O, 0, 1
RETENTION_IP_S = 396 * 86400 # 13 mois (~396 jours, obligation légale LCEN / décret 2021-1362)
def dossier_data():
return Path(os.environ.get("BETA_DATA", ICI / "data"))
def dossier_prive():
"""Dossier de données en 0700 (sous Windows, chmod est sans effet : voir README)."""
d = dossier_data()
d.mkdir(mode=0o700, parents=True, exist_ok=True)
try:
os.chmod(d, 0o700)
except OSError:
pass
return d
class _DataProxy:
def __truediv__(self, other):
return dossier_data() / other
def __getattr__(self, name):
return getattr(dossier_data(), name)
def __fspath__(self):
return str(dossier_data())
def __str__(self):
return str(dossier_data())
DATA = _DataProxy()
SCHEMA = """
CREATE TABLE IF NOT EXISTS codes(
id INTEGER PRIMARY KEY, label TEXT NOT NULL, code_hash TEXT NOT NULL,
created_at REAL NOT NULL, expires_at REAL, revoked_at REAL,
last_used_at REAL, uses INTEGER NOT NULL DEFAULT 0, max_sessions INTEGER NOT NULL DEFAULT 3);
CREATE TABLE IF NOT EXISTS sessions(
token_hash TEXT PRIMARY KEY, code_id INTEGER, tester_id INTEGER, ip TEXT, created_at REAL NOT NULL,
expires_at REAL NOT NULL, last_seen REAL);
CREATE TABLE IF NOT EXISTS attempts(
id INTEGER PRIMARY KEY, ts REAL NOT NULL, ip_hash TEXT NOT NULL, ok INTEGER NOT NULL, reason TEXT);
CREATE TABLE IF NOT EXISTS audit(
id INTEGER PRIMARY KEY, ts REAL NOT NULL, event TEXT NOT NULL, code_id INTEGER, ip_hash TEXT, detail TEXT);
CREATE TABLE IF NOT EXISTS feedback(
id INTEGER PRIMARY KEY, ts REAL NOT NULL, code_id INTEGER, tester_id INTEGER, page TEXT, text TEXT NOT NULL,
shot TEXT, viewport TEXT, ua TEXT, kind TEXT);
CREATE TABLE IF NOT EXISTS testers(
id INTEGER PRIMARY KEY, ts REAL NOT NULL, nom TEXT, prenom TEXT, email TEXT, tel TEXT,
naissance TEXT, mineur INTEGER, parent_nom TEXT, parent_email TEXT,
accord_participation INTEGER, rgpd INTEGER, confidentialite INTEGER, age_ok INTEGER,
suivi_reseaux INTEGER, source TEXT,
ip TEXT DEFAULT '', expire_ip_at REAL DEFAULT 0, actif INTEGER NOT NULL DEFAULT 1, last_seen REAL);
CREATE TABLE IF NOT EXISTS demo_profiles(
id INTEGER PRIMARY KEY, created_at REAL, first TEXT, last_initial TEXT, city TEXT, dept TEXT,
region TEXT, seed TEXT, bio TEXT);
CREATE TABLE IF NOT EXISTS demo_ads(
id INTEGER PRIMARY KEY, created_at REAL, profile_id INTEGER, category TEXT, title TEXT,
price INTEGER, unit TEXT, descr TEXT);
CREATE TABLE IF NOT EXISTS demo_convs(
id INTEGER PRIMARY KEY, created_at REAL, profile_id INTEGER, title TEXT, amount INTEGER, status TEXT);
CREATE TABLE IF NOT EXISTS demo_msgs(
id INTEGER PRIMARY KEY, created_at REAL, conv_id INTEGER, sender TEXT, text TEXT);
CREATE TABLE IF NOT EXISTS demo_activity(
id INTEGER PRIMARY KEY, created_at REAL, kind TEXT, text TEXT);
"""
def connect(path=None, check_same_thread=True):
dossier_prive()
ancien = os.umask(0o077) # base, -wal et -shm créés en 0600
try:
c = _ouvrir(path, check_same_thread)
finally:
os.umask(ancien)
return c
def _migrer(c):
# Migration douce pour les bases existantes
try:
cols_t = [r[1] for r in c.execute("PRAGMA table_info(testers)").fetchall()]
if "ip" not in cols_t:
c.execute("ALTER TABLE testers ADD COLUMN ip TEXT DEFAULT ''")
if "expire_ip_at" not in cols_t:
c.execute("ALTER TABLE testers ADD COLUMN expire_ip_at REAL DEFAULT 0")
if "actif" not in cols_t:
c.execute("ALTER TABLE testers ADD COLUMN actif INTEGER DEFAULT 1")
if "last_seen" not in cols_t:
c.execute("ALTER TABLE testers ADD COLUMN last_seen REAL")
cols_f = [r[1] for r in c.execute("PRAGMA table_info(feedback)").fetchall()]
if "tester_id" not in cols_f:
c.execute("ALTER TABLE feedback ADD COLUMN tester_id INTEGER")
# Avant ce correctif, un testeur libre était rangé dans code_id avec son id de testeur :
# impossible de les distinguer à coup sûr, ces lignes anciennes sont laissées telles quelles.
cols_s = [r[1] for r in c.execute("PRAGMA table_info(sessions)").fetchall()]
if "tester_id" not in cols_s:
c.execute("ALTER TABLE sessions ADD COLUMN tester_id INTEGER")
if "ip" not in cols_s:
c.execute("ALTER TABLE sessions ADD COLUMN ip TEXT")
# Anciennes bases : code_id NOT NULL empêche les sessions de testeurs libres (code_id NULL).
# SQLite ne sait pas retirer la contrainte : on recrée la table en gardant les sessions.
if any(r[1] == "code_id" and r[3] for r in c.execute("PRAGMA table_info(sessions)").fetchall()):
c.execute("ALTER TABLE sessions RENAME TO sessions_avant_null")
c.execute("CREATE TABLE sessions("
"token_hash TEXT PRIMARY KEY, code_id INTEGER, tester_id INTEGER, ip TEXT, created_at REAL NOT NULL,"
"expires_at REAL NOT NULL, last_seen REAL)")
c.execute("INSERT INTO sessions(token_hash,code_id,tester_id,ip,created_at,expires_at,last_seen) "
"SELECT token_hash,code_id,tester_id,ip,created_at,expires_at,last_seen FROM sessions_avant_null")
c.execute("DROP TABLE sessions_avant_null")
c.commit()
except Exception:
pass
def purger_anciennes_ip(c):
"""Anonymise les adresses IP échues (au-delà de 13 mois de rétention légale LCEN)."""
now = time.time()
try:
c.execute("UPDATE testers SET ip='[PURGE_13_MOIS]' WHERE expire_ip_at > 0 AND expire_ip_at <= ?", (now,))
c.execute("UPDATE sessions SET ip='[PURGE_13_MOIS]' WHERE expires_at <= ?", (now - RETENTION_IP_S,))
c.commit()
except Exception:
pass
def _supprimer_captures(c, where, args):
n = 0
for r in c.execute(f"SELECT shot FROM feedback WHERE shot IS NOT NULL AND ({where})", args).fetchall():
f = Path(str(DATA)) / "retours" / Path(str(r[0])).name # nom de fichier seul, jamais de chemin
try:
f.unlink()
n += 1
except FileNotFoundError:
pass
return n
def effacer_testeur(c, tester_id):
"""Effacement individuel (droit RGPD) : testeur, sessions, retours et captures liés. Renvoie le nb de retours."""
_supprimer_captures(c, "tester_id=?", (tester_id,))
n = c.execute("DELETE FROM feedback WHERE tester_id=?", (tester_id,)).rowcount
c.execute("DELETE FROM sessions WHERE tester_id=?", (tester_id,))
c.execute("DELETE FROM testers WHERE id=?", (tester_id,))
c.commit()
return n
def purger(c, avant_ts, journaux_jours=30, audit_jours=183, simulation=True):
"""Purge des testeurs inscrits avant `avant_ts` (avec leurs retours et captures), des retours par code
antérieurs, des tentatives de plus de `journaux_jours` et du journal de plus de `audit_jours`.
Simulation par défaut : renvoie seulement le bilan."""
now = time.time()
ids = [r[0] for r in c.execute("SELECT id FROM testers WHERE ts < ?", (avant_ts,)).fetchall()]
bilan = {
"testeurs": len(ids),
"retours_testeurs": sum(c.execute("SELECT COUNT(*) FROM feedback WHERE tester_id=?", (i,)).fetchone()[0] for i in ids),
"retours_codes": c.execute("SELECT COUNT(*) FROM feedback WHERE tester_id IS NULL AND ts < ?", (avant_ts,)).fetchone()[0],
"tentatives": c.execute("SELECT COUNT(*) FROM attempts WHERE ts < ?", (now - journaux_jours * 86400,)).fetchone()[0],
"audit": c.execute("SELECT COUNT(*) FROM audit WHERE ts < ?", (now - audit_jours * 86400,)).fetchone()[0],
}
if simulation:
return bilan
for i in ids:
effacer_testeur(c, i)
_supprimer_captures(c, "tester_id IS NULL AND ts < ?", (avant_ts,))
c.execute("DELETE FROM feedback WHERE tester_id IS NULL AND ts < ?", (avant_ts,))
c.execute("DELETE FROM attempts WHERE ts < ?", (now - journaux_jours * 86400,))
c.execute("DELETE FROM audit WHERE ts < ?", (now - audit_jours * 86400,))
c.commit()
journal(c, "purge", None, None, " ".join(f"{k}={v}" for k, v in bilan.items()))
return bilan
def _ouvrir(path, check_same_thread):
c = sqlite3.connect(str(path or dossier_prive() / "beta.sqlite"), timeout=10, check_same_thread=check_same_thread)
c.row_factory = sqlite3.Row
c.execute("PRAGMA journal_mode=WAL")
c.executescript(SCHEMA)
_migrer(c)
purger_anciennes_ip(c)
return c
def sel():
"""Sel local (créé au premier usage, hors git, jamais affiché)."""
f = dossier_prive() / "sel.bin"
try:
fd = os.open(f, os.O_WRONLY | os.O_CREAT | os.O_EXCL, 0o600)
with os.fdopen(fd, "wb") as fh:
fh.write(secrets.token_bytes(32))
except FileExistsError:
pass
return f.read_bytes()
def normaliser(code):
return "".join(ch for ch in str(code).upper() if ch in ALPHABET)
def hacher(code):
return hmac.new(sel(), normaliser(code).encode(), hashlib.sha256).hexdigest()
def hacher_ip(ip):
return hmac.new(sel(), b"ip:" + str(ip).encode(), hashlib.sha256).hexdigest()[:16]
def nouveau_code():
g = lambda: "".join(secrets.choice(ALPHABET) for _ in range(4))
return f"JRB-{g()}-{g()}-{g()}"
def journal(c, event, code_id=None, ip_hash=None, detail=None):
c.execute("INSERT INTO audit(ts,event,code_id,ip_hash,detail) VALUES(?,?,?,?,?)",
(time.time(), event, code_id, ip_hash, detail))
c.commit()
def creer_code(c, label, jours=30, max_sessions=3):
code = nouveau_code()
exp = time.time() + jours * 86400 if jours else None
cur = c.execute("INSERT INTO codes(label,code_hash,created_at,expires_at,max_sessions) VALUES(?,?,?,?,?)",
(label, hacher(code), time.time(), exp, max_sessions))
c.commit()
journal(c, "code_cree", cur.lastrowid, None, label)
return cur.lastrowid, code
def code_actif(row, now=None):
now = now or time.time()
return row["revoked_at"] is None and (row["expires_at"] is None or row["expires_at"] > now)
def verifier_code(c, saisi):
"""Compare en temps constant avec TOUS les codes (pas de sortie anticipée).
Retourne la ligne du code valide ou None."""
h = hacher(saisi)
trouve = None
for row in c.execute("SELECT * FROM codes").fetchall():
egal = hmac.compare_digest(row["code_hash"], h)
if egal and code_actif(row):
trouve = row
return trouve
+38
Voir le fichier
@@ -0,0 +1,38 @@
# EXEMPLE — NON APPLIQUÉ. À adapter puis à appliquer par Théo (sudo) après accord de Nils.
# Bloc à ajouter au Caddyfile du VPS, À CÔTÉ du bloc jobrunner.fr existant (qui reste protégé
# par basic_auth, inchangé).
# Options globales (bloc en tête du Caddyfile : à FUSIONNER avec l'existant, pas à dupliquer)
{
servers {
timeouts {
read_header 10s
read_body 15s
write 20s
idle 15s
}
max_header_size 16KB
}
}
beta.jobrunner.fr {
encode zstd gzip
header {
Strict-Transport-Security "max-age=31536000"
X-Content-Type-Options nosniff
Referrer-Policy no-referrer
X-Robots-Tag "noindex, nofollow"
}
# Chaîne : ce Caddy (VPS) -> wg -> Caddy de cornafserver -> Python sur 127.0.0.1:8830 (jamais exposé).
# <IP_WG_CORNAFSERVER> : à lire sur le serveur (ip a show wg1), ne pas deviner.
reverse_proxy <IP_WG_CORNAFSERVER>:8830 {
header_up X-Forwarded-For {remote_host}
header_up X-Forwarded-Proto https
}
request_body {
max_size 3MB
}
log {
output file /var/log/caddy/beta.jobrunner.fr.log
# pas de corps, pas de cookie : le serveur ne journalise lui-même ni IP ni cookie
}
}
+197
Voir le fichier
@@ -0,0 +1,197 @@
# Déploiement de la Bêta JobRunner (Appliqué en production le 29/10/2026)
Ce document décrit l'architecture déployée et les procédures d'exploitation pour la bêta testeurs de JobRunner.
---
## 1. Architecture en Production
```
INTERNET
│
▼
┌────────────────────────┐
│ VPS cornafsuisse │
│ IP : 179.237.102.233 │
│ Caddy (TLS Let's Enc) │
└───────────┬────────────┘
│
┌────────────────────────────┴────────────────────────────┐
│ │
admin.jobrunner.fr jobrunner.fr
(HTTP Basic Auth) www. / beta.jobrunner.fr
│ │
┌───────┴───────────────┐ │
│ Fichiers statiques │ │
│ /srv/jobrunner.fr │ │
│ (Espace projet) │ │
└───────┬───────────────┘ │
│ │
│ Route /_admin/api/* │
│ (en-tête X-Admin: 1) │
▼ ▼
Tunnel WireGuard wg2 (chiffré) Tunnel WireGuard wg2 (chiffré)
│ │
└────────────────────────────┬────────────────────────────┘
│
▼
┌────────────────────────┐
│ cornafserver (maison) │
│ IP wg2 : 10.88.88.2 │
│ nftables : port 8830 │
│ Service systemd user │
│ jobrunner-beta │
│ SQLite beta.sqlite │
└────────────────────────┘
```
---
## 2. Configuration DNS (Infomaniak)
| Enregistrement | Type | Cible | Rôle |
|---|---|---|---|
| `jobrunner.fr` | `A` | `179.237.102.233` | Bêta publique (redirigée vers `/__beta/gate`) |
| `www.jobrunner.fr` | `A` | `179.237.102.233` | Alias web |
| `beta.jobrunner.fr` | `A` | `179.237.102.233` | Sous-domaine dédié bêta |
| `admin.jobrunner.fr`| `A` | `179.237.102.233` | Espace projet & générateur de codes (accès restreint) |
---
## 3. Configuration Caddy (`cornafsuisse`)
Fichier : `/etc/caddy/Caddyfile`
### Espace projet & API Admin :
```caddy
admin.jobrunner.fr {
import /etc/caddy/jobrunner-auth.caddy
import /etc/caddy/securite.caddy
log {
format filter {
wrap json
fields {
request>remote_ip delete
request>client_ip delete
request>headers>X-Forwarded-For delete
request>headers>X-Real-Ip delete
}
}
}
encode zstd gzip
handle /_admin/api/* {
reverse_proxy 10.88.88.2:8830 {
header_up Host admin.jobrunner.fr
header_up X-Admin 1
header_up X-Forwarded-For {remote_host}
header_up X-Forwarded-Proto https
}
}
handle {
root * /srv/jobrunner.fr
file_server
}
}
```
### Bêta publique :
```caddy
jobrunner.fr, www.jobrunner.fr, beta.jobrunner.fr {
import /etc/caddy/securite.caddy
header {
X-Robots-Tag "noindex, nofollow, noarchive"
-Server
}
encode zstd gzip
reverse_proxy 10.88.88.2:8830 {
header_up Host {host}
header_up X-Forwarded-For {remote_host}
header_up X-Forwarded-Proto https
}
}
```
---
## 4. Configuration Serveur (`cornafserver`)
### Pare-feu nftables :
Fichier : `/etc/nftables.d/filtre_hote.nft`
Le port `8830` est autorisé uniquement depuis l'interface WireGuard `wg2` :
```nftables
table inet filtre_hote {
set tcp_wg2 {
type inet_service
flags interval
elements = { 22, 8000, 8095, 8830 }
}
}
```
### Service systemd utilisateur :
Fichier : `~/.config/systemd/user/jobrunner-beta.service`
- Écoute : `0.0.0.0:8830` (joignable par wg2 uniquement)
- Répertoire de travail : `/home/cornaf2049/jobrunner-beta`
- Variables d'environnement : `BETA_DATA=/home/cornaf2049/jobrunner-beta-data`
- Droits SQLite : `0600` sur `beta.sqlite`, `0700` sur `~/jobrunner-beta-data`
---
## 5. Exploitation & Gestion des Codes
### Depuis l'interface web (recommandé) :
Rendez-vous sur `https://admin.jobrunner.fr` :
1. Connectez-vous avec vos identifiants d'administration.
2. Dans la section **Gestion de la Bêta**, saisissez le nom ou la référence du testeur (ex. *Thomas D. (WhatsApp)*).
3. Choisissez la durée de validité (30 jours, 60 jours, 90 jours ou illimitée).
4. Cliquez sur **Créer le code**.
5. Le code `JRB-XXXX-XXXX-XXXX` s'affiche immédiatement avec :
- Un bouton pour copier le code seul.
- Un bouton pour copier le message d'invitation pré-rempli pour WhatsApp ou SMS.
### En ligne de commande sur `cornafserver` :
```bash
# Lister les codes actifs
python3 ~/jobrunner-beta/beta/codes.py liste
# Créer un code en CLI
python3 ~/jobrunner-beta/beta/codes.py generer --label "Testeur X" --jours 30
# Révoquer un code immédiatement
python3 ~/jobrunner-beta/beta/codes.py revoquer <ID>
# Consulter le journal d'activité
python3 ~/jobrunner-beta/beta/codes.py journal
# Consulter les retours testeurs reçus
python3 ~/jobrunner-beta/beta/codes.py retours
```
### Maintenance du service :
```bash
# Vérifier l'état du service
systemctl --user status jobrunner-beta
# Redémarrer après mise à jour
systemctl --user restart jobrunner-beta
# Consulter les logs en direct
journalctl --user -u jobrunner-beta -f -n 50
```
---
## 6. Procédure de Retour Arrière (Rollback)
En cas de besoin de suspension temporaire ou définitive :
1. **Couper le reverse proxy sur `cornafsuisse`** :
Restaurer la sauvegarde Caddy `/root/sauvegardes/caddy/Caddyfile.avant-admin-jobrunner-20261029-105849` et recharger Caddy (`caddy reload`).
2. **Stopper le service sur `cornafserver`** :
```bash
systemctl --user stop jobrunner-beta
```
3. **Fermer le port au pare-feu** :
Retirer le port 8830 de `/etc/nftables.d/filtre_hote.nft` et recharger nftables.
+81
Voir le fichier
@@ -0,0 +1,81 @@
#!/usr/bin/env python3
"""Ajoute l'enregistrement A beta.jobrunner.fr via l'API Infomaniak (à lancer sur cornafsuisse).
Le jeton est lu dans ~/.config/infomaniak/api_token, jamais affiché ni écrit ailleurs.
Mode par défaut : lecture seule + sauvegarde de la zone. --ajouter pour créer la ligne.
"""
import json
import os
import sys
import time
import urllib.error
import urllib.request
DOMAINE = "jobrunner.fr"
SOURCE = "beta"
CIBLE = "179.237.102.233"
TTL = 300
BASE = "https://api.infomaniak.com/2"
def appel(methode, chemin, jeton, corps=None):
donnees = json.dumps(corps).encode() if corps is not None else None
req = urllib.request.Request(BASE + chemin, data=donnees, method=methode)
req.add_header("Authorization", "Bearer " + jeton)
req.add_header("Accept", "application/json")
if donnees is not None:
req.add_header("Content-Type", "application/json")
try:
with urllib.request.urlopen(req, timeout=20) as r:
return json.loads(r.read().decode())
except urllib.error.HTTPError as e:
try:
return json.loads(e.read().decode())
except Exception:
return {"result": "error", "error": {"code": "http_%d" % e.code}}
def main():
ajouter = "--ajouter" in sys.argv
chemin_jeton = os.path.expanduser("~/.config/infomaniak/api_token")
with open(chemin_jeton, encoding="utf-8") as f:
jeton = f.read().strip()
zone = appel("GET", "/zones/%s/records" % DOMAINE, jeton)
if zone.get("result") != "success":
print("Erreur API (lecture) :", (zone.get("error") or {}).get("description") or (zone.get("error") or {}).get("code"))
return 1
dossier = os.path.expanduser("~/sauvegardes/dns")
os.makedirs(dossier, exist_ok=True)
nom = os.path.join(dossier, "zone-avant-jobrunner-beta-%s.json" % time.strftime("%Y%m%d-%H%M%S"))
with open(nom, "w", encoding="utf-8") as f:
json.dump(zone, f, ensure_ascii=False, indent=1)
os.chmod(nom, 0o600)
print("Sauvegarde de la zone :", nom, "(%d enregistrements)" % len(zone["data"]))
existants = [r for r in zone["data"] if r.get("source") == SOURCE]
print("Lignes A de la zone :")
for r in zone["data"]:
if r.get("type") == "A":
src = "@" if r.get("source") in ("", ".") else r.get("source")
print(" A %-12s -> %s (ttl %s)" % (src, r.get("target"), r.get("ttl")))
if existants:
print("Une ligne '%s' existe déjà :" % SOURCE, [(r["type"], r["target"]) for r in existants])
return 0
if not ajouter:
print("Simulation : '%s' absent. Relance avec --ajouter pour créer A %s -> %s." % (SOURCE, SOURCE, CIBLE))
return 0
rep = appel("POST", "/zones/%s/records" % DOMAINE, jeton,
{"type": "A", "source": SOURCE, "target": CIBLE, "ttl": TTL})
if rep.get("result") == "success":
print("OK : A %s.%s -> %s créé." % (SOURCE, DOMAINE, CIBLE))
return 0
print("Erreur API (création) :", (rep.get("error") or {}).get("description") or (rep.get("error") or {}).get("code"))
return 1
if __name__ == "__main__":
sys.exit(main())
+14
Voir le fichier
@@ -0,0 +1,14 @@
# EXEMPLE — NON APPLIQUÉ. Bots lents (une action toutes les 45 à 120 s), mêmes données que le serveur.
[Unit]
Description=JobRunner bêta : bots de démonstration
[Service]
WorkingDirectory=%h/jobrunner-beta
Environment=BETA_DATA=%h/jobrunner-beta-data
ExecStart=/usr/bin/python3 beta/bots.py
Restart=on-failure
UMask=0077
NoNewPrivileges=yes
[Install]
WantedBy=default.target
+18
Voir le fichier
@@ -0,0 +1,18 @@
# EXEMPLE — NON APPLIQUÉ. Unité systemd utilisateur (pas de sudo) sur cornafserver.
[Unit]
Description=JobRunner bêta (serveur Python, porte d'entrée par code)
[Service]
WorkingDirectory=%h/jobrunner-beta
Environment=BETA_HOST=127.0.0.1
Environment=BETA_PORT=8830
Environment=BETA_TRUST_PROXY=1
Environment=BETA_DATA=%h/jobrunner-beta-data
ExecStart=/usr/bin/python3 beta/server.py
Restart=on-failure
UMask=0077
NoNewPrivileges=yes
PrivateTmp=yes
[Install]
WantedBy=default.target
+139
Voir le fichier
@@ -0,0 +1,139 @@
"""Génère le formulaire testeur PDF (champs AcroForm) à la charte JobRunner.
python beta/pdf/generer_formulaire.py
Dépendances (locales, hors dépôt) : reportlab, fonttools, brotli.
Sortie : beta/static/pdf/formulaire-testeur-jobrunner.pdf
La police Chillax (woff2 du dépôt) est convertie en TTF temporaire (beta/pdf/*.ttf, ignoré par git).
"""
import sys
from pathlib import Path
from fontTools.ttLib import TTFont
from reportlab.lib.colors import HexColor
from reportlab.lib.pagesizes import A4
from reportlab.pdfbase import pdfmetrics
from reportlab.pdfbase.ttfonts import TTFont as RLFont
from reportlab.pdfgen import canvas
ICI = Path(__file__).resolve().parent
RACINE = ICI.parent.parent
SORTIE = ICI.parent / "static" / "pdf" / "formulaire-testeur-jobrunner.pdf"
FOND, SAUGE, TEXTE, CHAIR, FILET, DOUX = (HexColor(x) for x in ("#F2F0E6", "#8B9E90", "#2D2D2D", "#E8D5C4", "#E0DDD5", "#6B6B6B"))
def police(poids, nom):
ttf = ICI / f"chillax-{poids}.ttf"
if not ttf.exists():
f = TTFont(str(RACINE / "assets" / "fonts" / f"chillax-latin-{poids}-normal.woff2"))
f.flavor = None
f.save(str(ttf))
pdfmetrics.registerFont(RLFont(nom, str(ttf)))
def main():
police(400, "Chillax"); police(700, "Chillax-Bold")
SORTIE.parent.mkdir(parents=True, exist_ok=True)
c = canvas.Canvas(str(SORTIE), pagesize=A4, pageCompression=1)
c.setTitle("Formulaire testeur - JobRunner bêta"); c.setAuthor("JobRunner"); c.setSubject("Participation à la bêta de test")
W, Hh = A4
M = 46
f = c.acroForm
def fond():
c.setFillColor(FOND); c.rect(0, 0, W, Hh, stroke=0, fill=1)
def champ(nom, x, y, w, tip, h=22):
f.textfield(name=nom, tooltip=tip, x=x, y=y, width=w, height=h, borderStyle="solid", borderWidth=1,
borderColor=SAUGE, fillColor=HexColor("#FFFFFF"), textColor=TEXTE, forceBorder=True,
fontName="Helvetica", fontSize=11)
def case(nom, x, y, tip):
f.checkbox(name=nom, tooltip=tip, x=x, y=y, size=14, borderColor=SAUGE, fillColor=HexColor("#FFFFFF"),
textColor=TEXTE, forceBorder=True, buttonStyle="check", checked=False)
def texte(t, x, y, fonte="Chillax", taille=10.5, couleur=TEXTE):
c.setFont(fonte, taille); c.setFillColor(couleur); c.drawString(x, y, t)
def para(lignes, x, y, taille=9.5, inter=13):
for l in lignes:
texte(l, x, y, taille=taille); y -= inter
return y
def pied():
c.setStrokeColor(FILET); c.line(M, 50, W - M, 50)
texte("À renvoyer à contact@jobrunner.fr · JobRunner bêta : version d'essai, données fictives, paiements simulés.", M, 34, taille=8.5, couleur=DOUX)
# ---------- Page 1 ----------
fond()
c.drawImage(str(RACINE / "assets" / "img" / "logo.png"), M, Hh - 100, width=56, height=56, mask="auto")
texte("Formulaire testeur", M + 70, Hh - 70, "Chillax-Bold", 24)
texte("Bêta de test de JobRunner · à remplir à l'écran ou à imprimer", M + 70, Hh - 88, taille=10, couleur=DOUX)
c.setFillColor(SAUGE); c.roundRect(W - M - 90, Hh - 76, 90, 22, 11, stroke=0, fill=1)
texte("BÊTA", W - M - 62, Hh - 69, "Chillax-Bold", 11, FOND)
c.setFillColor(CHAIR); c.roundRect(M, Hh - 170, W - 2 * M, 52, 12, stroke=0, fill=1)
para(["Vous testez une version d'essai : tout est fictif, aucun paiement n'est réel (paiement SIMULÉ).",
"Contrepartie envisagée : suivre JobRunner sur les réseaux et, sous réserve de confirmation par",
"JobRunner, 1 an de Pass premium. Ce n'est pas encore une promesse ferme."], M + 12, Hh - 135, 9.5)
y = Hh - 210
texte("1. Vos coordonnées", M, y, "Chillax-Bold", 14); y -= 46
moitie = (W - 2 * M - 14) / 2
texte("Prénom", M, y + 26, taille=9.5, couleur=DOUX); champ("prenom", M, y, moitie, "Prénom")
texte("Nom", M + moitie + 14, y + 26, taille=9.5, couleur=DOUX); champ("nom", M + moitie + 14, y, moitie, "Nom")
y -= 50
texte("E-mail", M, y + 26, taille=9.5, couleur=DOUX); champ("email", M, y, moitie, "Adresse e-mail")
texte("Téléphone", M + moitie + 14, y + 26, taille=9.5, couleur=DOUX); champ("tel", M + moitie + 14, y, moitie, "Téléphone")
y -= 50
texte("Date de naissance (JJ/MM/AAAA)", M, y + 26, taille=9.5, couleur=DOUX); champ("naissance", M, y, moitie, "Date de naissance")
y -= 36
texte("2. Âge et accord parental", M, y, "Chillax-Bold", 14); y -= 22
case("age_15_ou_plus", M, y - 2, "J'ai 15 ans ou plus")
y = para(["J'ai 15 ans ou plus (participation impossible en dessous)."], M + 24, y + 1)
y -= 12
para(["Si j'ai entre 15 et 17 ans, le responsable légal remplit les trois champs ci-dessous :"], M, y, 9.5); y -= 52
texte("Nom et prénom du responsable légal", M, y + 26, taille=9.5, couleur=DOUX); champ("parent_nom", M, y, moitie, "Responsable légal")
texte("E-mail du responsable légal", M + moitie + 14, y + 26, taille=9.5, couleur=DOUX); champ("parent_email", M + moitie + 14, y, moitie, "E-mail du responsable légal")
y -= 30
case("accord_parental", M, y - 2, "Accord parental")
y = para(["Je suis le responsable légal et j'autorise ce mineur à participer à la bêta."], M + 24, y + 1)
pied()
c.showPage()
fond()
texte("Formulaire testeur JobRunner bêta (suite)", M, Hh - 60, "Chillax-Bold", 14)
y = Hh - 110
texte("3. Engagements (à cocher)", M, y, "Chillax-Bold", 14); y -= 24
blocs = [("accord_participation", "Accord de participation",
["J'accepte de participer à la bêta de JobRunner à titre bénévole, de donner mon avis",
"(ce qu'il faut garder ou changer) et je peux arrêter à tout moment."]),
("confidentialite", "Confidentialité de la bêta",
["Je garde la bêta confidentielle : pas de capture, de vidéo ni de description publique",
"sans l'accord de JobRunner. Mon code d'accès est personnel."]),
("rgpd", "Consentement RGPD minimal",
["J'accepte que JobRunner conserve ces informations uniquement pour gérer la bêta (accès,",
"contact, contrepartie). Pas de vente ni de transmission ; suppression sur simple demande",
"et au plus tard 6 mois après la fin de la bêta."]),
("suivi_reseaux", "Facultatif : réseaux sociaux",
["Je m'engage à suivre JobRunner sur les réseaux sociaux (comptes indiqués à l'envoi du code)."])]
for nom, titre, lignes in blocs:
case(nom, M, y - 2, titre)
texte(titre, M + 24, y, "Chillax-Bold", 10.5)
y = para(lignes, M + 24, y - 13, 9) - 8
y -= 6
texte("4. Signature", M, y, "Chillax-Bold", 14); y -= 46
texte("Fait à", M, y + 26, taille=9.5, couleur=DOUX); champ("lieu", M, y, moitie, "Lieu")
texte("Le (JJ/MM/AAAA)", M + moitie + 14, y + 26, taille=9.5, couleur=DOUX); champ("date_signature", M + moitie + 14, y, moitie, "Date")
y -= 50
texte("Signature (nom, ou signature manuscrite après impression) :", M, y + 26, taille=9.5, couleur=DOUX)
champ("signature", M, y - 12, W - 2 * M, "Signature", h=34)
pied()
c.showPage()
c.save()
print("PDF écrit :", SORTIE, SORTIE.stat().st_size, "octets")
if __name__ == "__main__":
main()
+802
Voir le fichier
@@ -0,0 +1,802 @@
"""Serveur de la bêta JobRunner (bibliothèque standard uniquement).
Sert le site statique du dépôt derrière une porte d'entrée par code d'accès,
injecte le bandeau « Bêta » et le bouton « Donner mon avis », et expose une
petite API locale (entrée, retours, formulaire testeur, flux de démo).
Lancement local : python beta/server.py (127.0.0.1:8830 par défaut)
Aucun appel sortant, aucun paiement, aucune clé.
"""
import base64
import hashlib
import json
import mimetypes
import os
import re
import secrets
import sys
import threading
import time
import shutil
import unicodedata
from datetime import date
from http import cookies
from http.server import BaseHTTPRequestHandler, ThreadingHTTPServer
from pathlib import Path
from urllib.parse import unquote, urlsplit
sys.path.insert(0, str(Path(__file__).resolve().parent))
import db # noqa: E402
RACINE = Path(__file__).resolve().parent.parent
STATIC = Path(__file__).resolve().parent / "static"
COOKIE = "jrb_s"
SESSION_S = 7 * 86400
FENETRE_S = 15 * 60
MAX_ECHECS_IP = int(os.environ.get("BETA_MAX_ECHECS_IP", "6"))
MAX_CONC_IP = int(os.environ.get("BETA_MAX_CONC_IP", "2"))
DELAI_ECHEC = 0.4
DELAI_TOTAL = 20 # secondes : ligne de requête + en-têtes + corps, puis la socket est fermée
MAX_ECHECS_GLOBAL = int(os.environ.get("BETA_MAX_ECHECS_GLOBAL", "60"))
FAIT_CONFIANCE_PROXY = os.environ.get("BETA_TRUST_PROXY") == "1"
# Hôte de l'espace projet. Le vhost public de Caddy ne transmet comme Host que jobrunner.fr / www / beta :
# un en-tête X-Admin envoyé par un visiteur du site public ne suffit donc plus.
ADMIN_HOST = os.environ.get("BETA_ADMIN_HOST", "admin.jobrunner.fr").lower()
MAX_CAPTURES_JOUR = int(os.environ.get("BETA_MAX_CAPTURES_JOUR", "30")) # par testeur ou par code
MAX_CAPTURES_OCTETS = int(os.environ.get("BETA_MAX_CAPTURES_MO", "500")) * 1_000_000 # total du dossier
MIN_LIBRE_OCTETS = int(os.environ.get("BETA_MIN_LIBRE_GO", "5")) * 1_000_000_000
EXT_OK = {".html", ".css", ".js", ".woff2", ".png", ".jpg", ".jpeg", ".svg", ".webp", ".ico", ".mp4", ".webm", ".gif", ".pdf"}
DOSSIERS_INTERDITS = {"beta", ".git", "docs", "node_modules", "design"}
CSP_APP = ("default-src 'self'; img-src 'self' https: data: blob:; media-src 'self' https: blob:; "
"style-src 'self' 'unsafe-inline'; script-src 'self' 'unsafe-inline'; font-src 'self' data:; "
"connect-src 'self'; frame-src 'none'; object-src 'none'; base-uri 'self'; form-action 'self'")
CSP_PAGE = ("default-src 'self'; img-src 'self' data:; style-src 'self' 'unsafe-inline'; "
"script-src 'self' 'unsafe-inline'; font-src 'self'; connect-src 'self'; frame-ancestors 'none'; "
"base-uri 'none'; form-action 'self'")
INJECTION = ('<link rel="stylesheet" href="/__beta/static/beta.css">'
'<script src="/__beta/static/beta.js" defer></script>')
EMAIL = re.compile(r"^[^@\s]{1,64}@[^@\s]{1,190}\.[^@\s]{2,}$")
TEL = re.compile(r"^[0-9 +().-]{6,20}$")
LOGOS = {"logo.png", "logo-official.jpg", "logo-square.png", "logo-transparent.png",
"logo-dark.svg", "logo-j.svg", "logo-light.svg"}
def chemin_sur(p):
"""Refuse tout segment '.' ou '..' (y compris encodé, même doublement), antislash, NUL, % résiduel."""
q = p
for _ in range(3):
q = unquote(q)
if "%" in q or "\\" in q or "\x00" in q or any(ord(ch) < 32 for ch in q):
return False
return not any(seg in (".", "..") for seg in p.split("/") + q.split("/"))
LIMITES_POST = {
"/__beta/api/enter": 2000,
"/__beta/api/tester": 8000,
"/__beta/api/feedback": 2_600_000,
"/_admin/api/codes/creer": 4000,
"/_admin/api/codes/supprimer": 1000,
"/_admin/api/testeurs/statut": 1000,
"/_admin/api/testeurs/supprimer": 1000,
"/__beta/logout": 100,
}
def a_controle(v):
return any(unicodedata.category(ch)[0] == "C" for ch in str(v))
def age(naissance, ref=None):
ref = ref or date.today()
y, m, d = (int(x) for x in naissance.split("-"))
return ref.year - y - ((ref.month, ref.day) < (m, d))
class ConnVerrouillee:
"""Verrou autour des seuls appels à la base (jamais autour des lectures/écritures réseau)."""
def __init__(self, conn):
self._c, self._v = conn, threading.RLock()
def execute(self, *a):
with self._v:
return self._c.execute(*a)
def commit(self):
with self._v:
self._c.commit()
class Handler(BaseHTTPRequestHandler):
protocol_version = "HTTP/1.0" # pas de keep-alive : une requête par connexion
timeout = 10 # client lent : la connexion est coupée, le serveur n'est jamais bloqué
server_version = "JobRunnerBeta"
sys_version = ""
def log_message(self, fmt, *a): # pas de journal HTTP (ni IP ni cookie) sauf demande
if os.environ.get("BETA_VERBOSE"):
sys.stderr.write("[beta] " + fmt % a + "\n")
def setup(self):
super().setup()
# minuterie globale : un client qui goutte-à-goutte (ligne, en-têtes ou corps) est coupé
self._minuterie = threading.Timer(DELAI_TOTAL, self._couper)
self._minuterie.daemon = True
self._minuterie.start()
def _couper(self):
try:
self.request.shutdown(2)
self.request.close()
except OSError:
pass
def finish(self):
self._minuterie.cancel()
super().finish()
# --- utilitaires -------------------------------------------------
@property
def c(self):
return self.server.conn
def ip(self):
if FAIT_CONFIANCE_PROXY:
xf = self.headers.get("X-Forwarded-For", "")
if xf:
return xf.split(",")[-1].strip() # dernier saut = ajouté par Caddy
return self.client_address[0]
def est_admin(self):
if self.headers.get("X-Admin") != "1":
return False
hote = (self.headers.get("Host") or "").strip().lower()
if ":" in hote and not hote.startswith("["):
hote = hote.rsplit(":", 1)[0] # port éventuel ; une IPv6 entre crochets ne vaut jamais ADMIN_HOST
return hote == ADMIN_HOST
def https(self):
return FAIT_CONFIANCE_PROXY and self.headers.get("X-Forwarded-Proto") == "https"
def envoyer(self, code, corps=b"", ctype="text/html; charset=utf-8", extra=None, csp=CSP_PAGE):
if isinstance(corps, str):
corps = corps.encode()
self.send_response(code)
self.send_header("Content-Type", ctype)
self.send_header("Content-Length", str(len(corps)))
self.send_header("Connection", "close")
self.send_header("X-Content-Type-Options", "nosniff")
self.send_header("Referrer-Policy", "no-referrer")
self.send_header("X-Robots-Tag", "noindex, nofollow")
if not any(k.lower() == "cache-control" for k, _ in (extra or [])):
self.send_header("Cache-Control", "no-store")
if csp:
self.send_header("Content-Security-Policy", csp)
for k, v in (extra or []):
self.send_header(k, v)
self.end_headers()
if self.command != "HEAD":
self.wfile.write(corps)
def json(self, code, obj, extra=None):
self.envoyer(code, json.dumps(obj, ensure_ascii=False), "application/json; charset=utf-8", extra)
def corps_json(self, limite=32_000):
brut = getattr(self, "_corps", b"")
if not brut or len(brut) > limite:
return None
try:
return json.loads(brut)
except Exception:
return None
def session(self):
brut = self.headers.get("Cookie", "")
# Le navigateur peut envoyer plusieurs jrb_s (ancien cookie resté sur un autre chemin ou domaine) :
# SimpleCookie n'en garde qu'un, on les essaie donc tous.
jetons = [m.strip()[len(COOKIE) + 1:] for m in brut.split(";") if m.strip().startswith(COOKIE + "=")]
now = time.time()
s = None
for tok in jetons[:5]:
h = hashlib.sha256(tok.encode()).hexdigest()
s = self.c.execute("SELECT * FROM sessions WHERE token_hash=? AND expires_at>?", (h, now)).fetchone()
if s:
break
if not s:
return None
# Cas 1 : session testeur direct (inscription libre)
if s["tester_id"]:
tester = self.c.execute("SELECT * FROM testers WHERE id=?", (s["tester_id"],)).fetchone()
if not tester or not tester["actif"]:
return None
return {
"hash": h,
"tester": tester,
"code": {"id": s["code_id"] or s["tester_id"], "label": f"{tester['prenom']} {tester['nom']}"}
}
# Cas 2 : session code classique
if s["code_id"]:
code = self.c.execute("SELECT * FROM codes WHERE id=?", (s["code_id"],)).fetchone()
if not code or not db.code_actif(code, now):
return None
return {"hash": h, "code": code}
return None
def csrf_ok(self):
if self.est_admin():
return True
if self.headers.get("X-Beta") != "1":
return False
o = self.headers.get("Origin")
return not o or urlsplit(o).netloc in (self.headers.get("Host"), "admin.jobrunner.fr", "jobrunner.fr", "beta.jobrunner.fr")
def bloque(self, iph):
now = time.time()
n_ip = self.c.execute("SELECT COUNT(*) FROM attempts WHERE ip_hash=? AND ok=0 AND ts>?", (iph, now - FENETRE_S)).fetchone()[0]
n_all = self.c.execute("SELECT COUNT(*) FROM attempts WHERE ok=0 AND ts>?", (now - 3600,)).fetchone()[0]
if n_all >= MAX_ECHECS_GLOBAL:
self._delai = 1.0 # le compteur global n'ajoute qu'un délai : un code valide passe toujours
return n_ip >= MAX_ECHECS_IP
# --- routage -----------------------------------------------------
def do_HEAD(self):
self.do_GET()
def do_GET(self):
self._get()
def lire_corps(self, limite):
"""Lit le corps avec plafond de taille ET délai total (10 s) ; None si refusé."""
try:
n = int(self.headers.get("Content-Length") or 0)
except ValueError:
return None
if n < 0 or n > limite:
return None
fin, buf = time.time() + 10, b""
while len(buf) < n:
reste = fin - time.time()
if reste <= 0:
return None
try:
self.connection.settimeout(reste)
ch = self.rfile.read1(min(65536, n - len(buf)))
except OSError:
return None
if not ch:
return None
buf += ch
return buf
def do_POST(self):
p = urlsplit(self.path).path
self._corps, self._delai = b"", 0
self.close_connection = True # on ne réutilise pas la connexion après un refus
if not chemin_sur(p) or p not in LIMITES_POST:
return self.json(404, {"erreur": "inconnu"})
if not self.csrf_ok():
return self.json(403, {"erreur": "requête refusée"})
if p == "/__beta/api/feedback":
if not self.session(): # authentification AVANT de lire un gros corps
return self.json(401, {"erreur": "session expirée, ressaisir le code"})
corps = self.lire_corps(LIMITES_POST[p])
if corps is None:
return self.json(413, {"erreur": "corps trop gros, trop lent ou invalide"})
self._corps = corps
self.close_connection = False
self._post()
def _get(self):
p = urlsplit(self.path).path
if not chemin_sur(p):
return self.envoyer(404, "Introuvable", "text/plain; charset=utf-8")
if p == "/robots.txt":
return self.envoyer(200, "User-agent: *\nDisallow: /\n", "text/plain")
if p == "/__beta/healthz":
return self.json(200, {"ok": True})
s = self.session()
if p == "/__beta/gate":
# La gate redirige désormais vers le formulaire libre (ou direct sur l'app si connecté)
loc = "/app.html" if s else "/__beta/formulaire"
return self.envoyer(302, b"", extra=[("Location", loc)])
if p == "/__beta/formulaire":
if s:
return self.envoyer(302, b"", extra=[("Location", "/app.html")])
return self.envoyer(200, (STATIC / "formulaire.html").read_bytes())
if p.startswith("/__beta/static/"):
return self.fichier(STATIC, p[len("/__beta/static/"):], cache=True)
if p.startswith("/assets/fonts/"): # polices : dossier fixe, woff2 uniquement
return self.fichier(RACINE / "assets" / "fonts", p[len("/assets/fonts/"):], ext=".woff2")
if p == "/assets/css/fonts.css":
return self.fichier(RACINE / "assets" / "css", "fonts.css")
if p.startswith("/assets/img/") and p[len("/assets/img/"):] in LOGOS: # logos : liste blanche
return self.fichier(RACINE / "assets" / "img", p[len("/assets/img/"):])
if p == "/_admin/api/codes/liste":
return self.admin_liste_codes()
if p == "/_admin/api/candidatures/liste":
return self.admin_liste_candidatures()
if not s:
if p.endswith(".html") or p == "/":
return self.envoyer(302, b"", extra=[("Location", "/__beta/formulaire")])
return self.envoyer(401, "Accès réservé aux testeurs inscrits.", "text/plain; charset=utf-8")
if p == "/":
return self.envoyer(302, b"", extra=[("Location", "/app.html")])
if p.startswith("/__beta/avatar/"):
return self.avatar(p[len("/__beta/avatar/"):])
if p == "/__beta/api/demo":
return self.json(200, self.flux_demo())
if p == "/__beta/api/me":
return self.json(200, {"label": s["code"]["label"]})
if p == "/__beta/logout": # F5 : un GET ne change plus l'état, déconnexion par POST seulement
return self.envoyer(405, "Utiliser le bouton Quitter.", "text/plain; charset=utf-8", extra=[("Allow", "POST")])
if p.startswith("/__beta/"):
return self.envoyer(404, "Introuvable", "text/plain; charset=utf-8")
self.fichier(RACINE, p.lstrip("/") or "index.html", app=True)
def _post(self):
p = urlsplit(self.path).path
if not chemin_sur(p):
return self.json(404, {"erreur": "inconnu"})
if not self.csrf_ok():
return self.json(403, {"erreur": "requête refusée"})
if p == "/__beta/api/enter":
return self.entrer()
if p == "/__beta/api/tester":
return self.formulaire_testeur()
if p == "/_admin/api/codes/creer":
return self.admin_creer_code()
if p == "/_admin/api/codes/supprimer":
return self.admin_supprimer_code()
if p == "/_admin/api/testeurs/statut":
return self.admin_statut_testeur()
if p == "/_admin/api/testeurs/supprimer":
return self.admin_supprimer_testeur()
s = self.session()
if not s:
return self.json(401, {"erreur": "session expirée, ressaisir le code"})
if p == "/__beta/api/feedback":
return self.retour(s)
if p == "/__beta/logout":
return self.deconnecter(s)
self.json(404, {"erreur": "inconnu"})
# --- fichiers ----------------------------------------------------
def fichier(self, base, rel, cache=False, app=False, ext=None):
try:
if "\x00" in rel or "\\" in rel:
raise ValueError
cible = (base / rel).resolve()
parties = cible.relative_to(base.resolve()).parts
except Exception:
return self.envoyer(404, "Introuvable", "text/plain; charset=utf-8")
if app and (not parties or parties[0] in DOSSIERS_INTERDITS or any(x.startswith(".") for x in parties)):
return self.envoyer(404, "Introuvable", "text/plain; charset=utf-8")
if not cible.is_file() or cible.suffix.lower() not in EXT_OK or (ext and cible.suffix.lower() != ext):
return self.envoyer(404, "Introuvable", "text/plain; charset=utf-8")
data = cible.read_bytes()
suf = cible.suffix.lower()
ctype = mimetypes.guess_type(cible.name)[0] or "application/octet-stream"
if suf == ".html":
txt = data.decode("utf-8", "replace")
if app:
i = txt.lower().rfind("</body>") # le DERNIER : un </body> peut apparaître dans une chaîne JS
txt = txt[:i] + INJECTION + txt[i:] if i >= 0 else txt + INJECTION
return self.envoyer(200, txt, "text/html; charset=utf-8", csp=CSP_APP if app else CSP_PAGE)
if suf == ".js":
ctype = "text/javascript; charset=utf-8"
extra = [("Cache-Control", "no-cache")]
self.envoyer(200, data, ctype, extra=extra, csp=None)
# --- entrée par code ---------------------------------------------
def entrer(self):
iph, srv = db.hacher_ip(self.ip()), self.server
with srv.verrou_ip: # concurrence bornée PAR IP (pas globale)
occupe = srv.conc.get(iph, 0) >= MAX_CONC_IP
if not occupe:
srv.conc[iph] = srv.conc.get(iph, 0) + 1
if occupe:
return self.json(429, {"erreur": "Trop de requêtes simultanées, réessayez."}, [("Retry-After", "5")])
try:
st, obj, extra, delai = self._entrer(iph)
finally:
with srv.verrou_ip:
srv.conc[iph] -= 1
if srv.conc[iph] <= 0:
del srv.conc[iph]
if delai:
time.sleep(delai) # AUCUN verrou ni sémaphore tenu pendant le délai
self.json(st, obj, extra)
def _entrer(self, iph):
with self.server.verrou_entree: # vérification de la limite + enregistrement : atomiques
bloque = self.bloque(iph)
tentative = None
if not bloque: # tentative « en attente » comptée comme échec tant qu'elle n'a pas réussi
tentative = self.c.execute("INSERT INTO attempts(ts,ip_hash,ok,reason) VALUES(?,?,0,?)",
(time.time(), iph, "en attente")).lastrowid
self.c.commit()
if bloque:
db.journal(self.c, "entree_bloquee", None, iph, "trop d'échecs")
return (429, {"erreur": "Trop de tentatives. Réessayez dans 15 minutes."}, [("Retry-After", str(FENETRE_S))], 0)
d = self.corps_json(2000) or {}
saisi = str(d.get("code", ""))[:64]
row = db.verifier_code(self.c, saisi) if len(db.normaliser(saisi)) >= 8 else None
now = time.time()
if not row:
self.c.execute("UPDATE attempts SET reason=? WHERE id=?", ("code invalide", tentative))
self.c.commit()
db.journal(self.c, "entree_refusee", None, iph, "code invalide, révoqué ou expiré")
return (401, {"erreur": "Code invalide, révoqué ou expiré."}, None, max(self._delai, DELAI_ECHEC))
tok = secrets.token_urlsafe(32)
h = hashlib.sha256(tok.encode()).hexdigest()
exp = min(now + SESSION_S, row["expires_at"] or now + SESSION_S)
self.c.execute("INSERT INTO sessions(token_hash,code_id,created_at,expires_at,last_seen) VALUES(?,?,?,?,?)", (h, row["id"], now, exp, now))
vieux = self.c.execute("SELECT token_hash FROM sessions WHERE code_id=? ORDER BY created_at DESC LIMIT -1 OFFSET ?",
(row["id"], row["max_sessions"])).fetchall()
for v in vieux: # limite de sessions simultanées : on retire les plus anciennes
self.c.execute("DELETE FROM sessions WHERE token_hash=?", (v[0],))
self.c.execute("UPDATE codes SET uses=uses+1,last_used_at=? WHERE id=?", (now, row["id"]))
self.c.execute("UPDATE attempts SET ok=1, reason=? WHERE id=?", ("ok", tentative))
self.c.commit()
db.journal(self.c, "entree_ok", row["id"], iph, None)
attrs = f"{COOKIE}={tok}; Path=/; HttpOnly; SameSite=Lax; Max-Age={int(exp - now)}"
if self.https():
attrs += "; Secure"
return (200, {"ok": True, "suite": "/app.html"}, [("Set-Cookie", attrs)], self._delai) # saturation globale : délai seul
def deconnecter(self, s):
self.c.execute("DELETE FROM sessions WHERE token_hash=?", (s["hash"],))
self.c.commit()
db.journal(self.c, "sortie", s["code"]["id"], db.hacher_ip(self.ip()))
self.json(200, {"ok": True, "suite": "/__beta/gate"},
[("Set-Cookie", f"{COOKIE}=; Path=/; Max-Age=0; HttpOnly; SameSite=Lax")])
# --- retours -----------------------------------------------------
def retour(self, s):
d = self.corps_json(2_500_000)
if not d:
return self.json(400, {"erreur": "requête invalide"})
texte = str(d.get("text", "")).strip()[:4000]
if len(texte) < 3:
return self.json(400, {"erreur": "Écrivez au moins quelques mots."})
now = time.time()
n = self.c.execute(*self._filtre_auteur(s, "SELECT COUNT(*) FROM feedback WHERE ts>?", (now - 60,))).fetchone()[0]
if n >= 10:
return self.json(429, {"erreur": "Un peu de calme : 10 retours par minute maximum."})
kind = d.get("kind") if d.get("kind") in ("garder", "changer", "bug", "autre") else "autre"
shot = None
img = d.get("screenshot")
if img:
m = re.match(r"^data:image/(png|jpeg|webp);base64,([A-Za-z0-9+/=]+)$", str(img))
if not m:
return self.json(400, {"erreur": "capture invalide"})
brut = base64.b64decode(m.group(2))
if len(brut) > 1_500_000:
return self.json(413, {"erreur": "capture trop lourde (1,5 Mo max)"})
sig = {"png": b"\x89PNG", "jpeg": b"\xff\xd8\xff", "webp": b"RIFF"}[m.group(1)]
if not brut.startswith(sig):
return self.json(400, {"erreur": "capture invalide"})
dossier = db.DATA / "retours"
dossier.mkdir(parents=True, exist_ok=True)
refus = self.capture_refusee(s, dossier, len(brut), now)
if refus:
return self.json(507 if "espace" in refus else 429, {"erreur": refus})
shot = f"{int(now)}-{secrets.token_hex(4)}.{'jpg' if m.group(1) == 'jpeg' else m.group(1)}"
(dossier / shot).write_bytes(brut)
tid = s["tester"]["id"] if s.get("tester") else None
cid = None if tid else s["code"]["id"] # testeur libre : pas de code, on ne mélange plus les deux identifiants
cur = self.c.execute(
"INSERT INTO feedback(ts,code_id,tester_id,page,text,shot,viewport,ua,kind) VALUES(?,?,?,?,?,?,?,?,?)",
(now, cid, tid, "".join(ch for ch in str(d.get("page", "")) if unicodedata.category(ch)[0] != "C")[:200], texte, shot,
"".join(ch for ch in str(d.get("viewport", "")) if unicodedata.category(ch)[0] != "C")[:30], self.headers.get("User-Agent", "")[:200], kind))
self.c.commit()
self.json(200, {"ok": True, "id": cur.lastrowid})
@staticmethod
def _filtre_auteur(s, sql, args):
if s.get("tester"):
return sql + " AND tester_id=?", args + (s["tester"]["id"],)
return sql + " AND code_id=? AND tester_id IS NULL", args + (s["code"]["id"],)
def capture_refusee(self, s, dossier, taille, now):
"""Plafonds de stockage des captures (M4) : par jour et par auteur, total du dossier, espace libre."""
n = self.c.execute(*self._filtre_auteur(s, "SELECT COUNT(*) FROM feedback WHERE shot IS NOT NULL AND ts>?",
(now - 86400,))).fetchone()[0]
if n >= MAX_CAPTURES_JOUR:
return f"{MAX_CAPTURES_JOUR} captures par jour maximum : envoyez le texte seul."
total = sum(f.stat().st_size for f in dossier.iterdir() if f.is_file())
if total + taille > MAX_CAPTURES_OCTETS:
return "Stockage des captures plein : envoyez le texte seul."
if shutil.disk_usage(dossier).free - taille < MIN_LIBRE_OCTETS:
return "Plus assez d'espace disque pour les captures : envoyez le texte seul."
return None
# --- formulaire testeur (version web du PDF) ---------------------
def formulaire_testeur(self):
raw_ip = self.ip()
iph = db.hacher_ip(raw_ip)
now = time.time()
n = self.c.execute("SELECT COUNT(*) FROM audit WHERE event='formulaire' AND ip_hash=? AND ts>?", (iph, now - 3600)).fetchone()[0]
if n >= 10:
return self.json(429, {"erreur": "Trop d'envois depuis ce réseau. Réessayez plus tard."})
d = self.corps_json(8000)
if not d:
return self.json(400, {"erreur": "requête invalide"})
if d.get("site_web"): # champ piège pour les robots
return self.json(200, {"ok": True, "suite": "/app.html"})
g = lambda k, n=120: str(d.get(k, "")).strip()[:n]
nom, prenom, email, tel, nais = g("nom"), g("prenom"), g("email", 254), g("tel", 20), g("naissance", 10)
err = []
if any(a_controle(d.get(k, "")) for k in ("nom", "prenom", "parent_nom", "email", "parent_email", "tel", "naissance")):
return self.json(400, {"erreur": "caractères de contrôle interdits"})
if not nom or not prenom:
err.append("nom et prénom requis")
if not EMAIL.match(email):
err.append("e-mail invalide")
if not TEL.match(tel):
err.append("téléphone invalide")
try:
a = age(nais)
if not 0 <= a < 120:
raise ValueError
except Exception:
return self.json(400, {"erreur": "date de naissance invalide (AAAA-MM-JJ)"})
for k, lab in (("accord_participation", "accord de participation"), ("rgpd", "consentement RGPD & conservation IP"),
("confidentialite", "engagement de confidentialité")):
if not d.get(k):
err.append(lab + " à cocher")
if a < 15:
err.append("la participation est réservée aux personnes de 15 ans ou plus")
mineur = 1 if a < 18 else 0
pn, pe = g("parent_nom"), g("parent_email", 254)
if mineur and a >= 15 and (not pn or not EMAIL.match(pe) or not d.get("accord_parental")):
err.append("accord parental requis (nom, e-mail du responsable légal et case cochée)")
if err:
return self.json(400, {"erreur": "; ".join(err)})
# Conservation légale LCEN de l'adresse IP pour 13 mois
expire_ip_at = now + db.RETENTION_IP_S
existant = self.c.execute("SELECT * FROM testers WHERE email=? ORDER BY id DESC LIMIT 1", (email,)).fetchone()
if existant:
if not existant["actif"]:
return self.json(403, {"erreur": "Votre accès a été désactivé par l'administration."})
tester_id = existant["id"]
self.c.execute(
"UPDATE testers SET nom=?, prenom=?, tel=?, naissance=?, mineur=?, parent_nom=?, parent_email=?, "
"ip=?, expire_ip_at=?, last_seen=?, source=? WHERE id=?",
(nom, prenom, tel, nais, mineur, pn if mineur else None, pe if mineur else None,
raw_ip, expire_ip_at, now, "web", tester_id)
)
else:
cur = self.c.execute(
"INSERT INTO testers(ts,nom,prenom,email,tel,naissance,mineur,parent_nom,parent_email,"
"accord_participation,rgpd,confidentialite,age_ok,suivi_reseaux,source,ip,expire_ip_at,actif,last_seen) "
"VALUES(?,?,?,?,?,?,?,?,?,1,1,1,1,?,?,?,?,1,?)",
(now, nom, prenom, email, tel, nais, mineur, pn if mineur else None, pe if mineur else None,
1 if d.get("suivi_reseaux") else 0, "web", raw_ip, expire_ip_at, now)
)
tester_id = cur.lastrowid
# Création immédiate de la session : inscription libre donne accès direct à la bêta
tok = secrets.token_urlsafe(32)
h = hashlib.sha256(tok.encode()).hexdigest()
exp = now + SESSION_S
self.c.execute("INSERT INTO sessions(token_hash,tester_id,code_id,ip,created_at,expires_at,last_seen) VALUES(?,?,?,?,?,?,?)",
(h, tester_id, None, raw_ip, now, exp, now))
self.c.commit()
db.journal(self.c, "inscription_libre", None, iph, f"tester_id={tester_id}")
attrs = f"{COOKIE}={tok}; Path=/; HttpOnly; SameSite=Lax; Max-Age={SESSION_S}"
if self.https():
attrs += "; Secure"
return self.json(200, {"ok": True, "suite": "/app.html"}, [("Set-Cookie", attrs)])
# --- administration (depuis admin.jobrunner.fr) -------------------
def admin_creer_code(self):
if not self.est_admin():
return self.json(403, {"erreur": "accès réservé à l'administration"})
try:
d = json.loads(self._corps.decode("utf-8"))
except Exception:
return self.json(400, {"erreur": "JSON invalide"})
label = str(d.get("label", "")).strip()
if not label:
return self.json(400, {"erreur": "Le nom ou référence du testeur est obligatoire."})
if a_controle(label):
return self.json(400, {"erreur": "Caractères non autorisés."})
if len(label) > 100:
return self.json(400, {"erreur": "Label trop long (max 100 car.)."})
jours = d.get("jours", 30)
try:
jours = int(jours)
if jours < 0 or jours > 365:
jours = 30
except (TypeError, ValueError):
jours = 30
sessions = d.get("sessions", 3)
try:
sessions = int(sessions)
if sessions < 1 or sessions > 10:
sessions = 3
except (TypeError, ValueError):
sessions = 3
cid, code = db.creer_code(self.c, label, jours, sessions)
exp = time.time() + jours * 86400 if jours else None
return self.json(200, {
"ok": True,
"id": cid,
"code": code,
"label": label,
"jours": jours,
"expires_at": exp,
"created_at": time.time()
})
def admin_supprimer_code(self):
if not self.est_admin():
return self.json(403, {"erreur": "accès réservé à l'administration"})
try:
d = json.loads(self._corps.decode("utf-8"))
code_id = int(d.get("id"))
except Exception:
return self.json(400, {"erreur": "ID de code invalide"})
self.c.execute("DELETE FROM sessions WHERE code_id=?", (code_id,))
self.c.execute("DELETE FROM codes WHERE id=?", (code_id,))
self.c.execute("UPDATE audit SET code_id=NULL WHERE code_id=?", (code_id,))
self.c.commit()
db.journal(self.c, "code_supprime", None, None, f"id={code_id}")
return self.json(200, {"ok": True, "id": code_id})
def admin_liste_candidatures(self):
if not self.est_admin():
return self.json(403, {"erreur": "accès réservé à l'administration"})
now = time.time()
lignes = []
for r in self.c.execute("SELECT id, ts, nom, prenom, email, tel, naissance, mineur, parent_nom, parent_email, suivi_reseaux, ip, expire_ip_at, actif, last_seen FROM testers ORDER BY id DESC LIMIT 100"):
nb_sessions = self.c.execute("SELECT COUNT(*) FROM sessions WHERE tester_id=? AND expires_at>?", (r["id"], now)).fetchone()[0]
lignes.append({
"id": r["id"],
"ts": r["ts"],
"nom": r["nom"],
"prenom": r["prenom"],
"email": r["email"],
"tel": r["tel"],
"naissance": r["naissance"],
"mineur": bool(r["mineur"]),
"parent_nom": r["parent_nom"],
"parent_email": r["parent_email"],
"suivi_reseaux": bool(r["suivi_reseaux"]),
"ip": r["ip"] or "",
"expire_ip_at": r["expire_ip_at"] or 0,
"actif": bool(r["actif"]),
"last_seen": r["last_seen"],
"sessions_actives": nb_sessions
})
return self.json(200, {"ok": True, "candidatures": lignes})
def admin_statut_testeur(self):
if not self.est_admin():
return self.json(403, {"erreur": "accès réservé à l'administration"})
try:
d = json.loads(self._corps.decode("utf-8"))
tester_id = int(d.get("id"))
actif = 1 if d.get("actif") else 0
except Exception:
return self.json(400, {"erreur": "Paramètres invalides"})
self.c.execute("UPDATE testers SET actif=? WHERE id=?", (actif, tester_id))
if not actif:
self.c.execute("DELETE FROM sessions WHERE tester_id=?", (tester_id,))
self.c.commit()
db.journal(self.c, "testeur_statut", None, None, f"id={tester_id} actif={actif}")
return self.json(200, {"ok": True, "id": tester_id, "actif": actif})
def admin_supprimer_testeur(self):
if not self.est_admin():
return self.json(403, {"erreur": "accès réservé à l'administration"})
try:
d = json.loads(self._corps.decode("utf-8"))
tester_id = int(d.get("id"))
except Exception:
return self.json(400, {"erreur": "ID invalide"})
n = db.effacer_testeur(self.c, tester_id)
db.journal(self.c, "testeur_supprime", None, None, f"id={tester_id} retours={n}")
return self.json(200, {"ok": True, "id": tester_id})
def admin_liste_codes(self):
if not self.est_admin():
return self.json(403, {"erreur": "accès réservé à l'administration"})
now = time.time()
lignes = []
for r in self.c.execute("SELECT id, label, created_at, expires_at, uses, last_used_at, revoked_at FROM codes ORDER BY id DESC LIMIT 50"):
st = "actif"
if r["revoked_at"]:
st = "révoqué"
elif r["expires_at"] and r["expires_at"] <= now:
st = "expiré"
lignes.append({
"id": r["id"],
"label": r["label"],
"created_at": r["created_at"],
"expires_at": r["expires_at"],
"uses": r["uses"],
"last_used_at": r["last_used_at"],
"status": st
})
return self.json(200, {"ok": True, "codes": lignes})
# --- démo --------------------------------------------------------
def flux_demo(self):
q = self.c.execute
profils = [dict(r) for r in q("SELECT * FROM demo_profiles ORDER BY id")]
annonces = [dict(r) for r in q("SELECT * FROM demo_ads ORDER BY id")]
convs = []
for r in q("SELECT * FROM demo_convs ORDER BY id").fetchall():
c = dict(r)
c["messages"] = [dict(m) for m in q("SELECT id,sender,text,created_at FROM demo_msgs WHERE conv_id=? ORDER BY id", (r["id"],))]
convs.append(c)
act = [dict(r) for r in q("SELECT * FROM demo_activity ORDER BY id DESC LIMIT 15")]
return {"profiles": profils, "ads": annonces, "convs": convs, "activity": act, "ts": time.time()}
def avatar(self, nom):
seed = re.sub(r"[^a-zA-Z0-9]", "", nom.replace(".svg", ""))[:40] or "x"
h = int(hashlib.sha256(seed.encode()).hexdigest()[:6], 16)
fonds = ["#8B9E90", "#E8D5C4", "#C9D3CB", "#D9C7B3", "#A9B8AD"]
ini = (seed[:1] or "?").upper()
svg = (f'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><rect width="100" height="100" fill="{fonds[h % 5]}"/>'
f'<circle cx="50" cy="38" r="18" fill="#F2F0E6"/><path d="M14 100c4-26 20-36 36-36s32 10 36 36z" fill="#F2F0E6"/>'
f'<text x="50" y="96" text-anchor="middle" font-size="14" fill="#2D2D2D" font-family="sans-serif">{ini}</text></svg>')
self.envoyer(200, svg, "image/svg+xml", extra=[("Cache-Control", "public, max-age=3600")], csp=None)
class Serveur(ThreadingHTTPServer):
daemon_threads = True
def __init__(self, addr, conn):
super().__init__(addr, Handler)
self.conn = ConnVerrouillee(conn)
self.conc, self.verrou_ip = {}, threading.Lock()
self.verrou_entree = threading.RLock()
self.connexions = threading.BoundedSemaphore(64) # plafond de connexions simultanées
def process_request(self, request, client_address):
if not self.connexions.acquire(blocking=False):
try:
request.close()
finally:
return
super().process_request(request, client_address)
def process_request_thread(self, request, client_address):
try:
super().process_request_thread(request, client_address)
finally:
self.connexions.release()
def main():
host = os.environ.get("BETA_HOST", "127.0.0.1")
port = int(os.environ.get("BETA_PORT", "8830"))
conn = db.connect(check_same_thread=False)
srv = Serveur((host, port), conn)
print(f"Bêta JobRunner sur http://{host}:{port}/ (données : {db.DATA})", flush=True)
try:
srv.serve_forever()
except KeyboardInterrupt:
pass
if __name__ == "__main__":
main()
+27
Voir le fichier
@@ -0,0 +1,27 @@
/* Couche bêta injectée sur chaque page : bandeau, bouton d'avis, fenêtre d'avis */
:root{--jrb-h:24px}
html{scroll-padding-top:var(--jrb-h)}
body{padding-top:var(--jrb-h)!important}
#desktop-navbar{top:var(--jrb-h)!important}
#jrb-bandeau{position:fixed;top:0;left:0;right:0;height:var(--jrb-h);z-index:2147483000;background:#2D2D2D;color:#F2F0E6;font:600 12px/var(--jrb-h) Chillax,system-ui,sans-serif;text-align:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;padding:0 8px}
#jrb-bandeau b{background:#8B9E90;color:#F2F0E6;border-radius:999px;padding:1px 9px;margin-right:6px}
#jrb-bandeau a{color:#E8D5C4;margin-left:10px}
#jrb-avis-btn{position:fixed;right:14px;bottom:14px;z-index:2147482000;font:600 14px Chillax,system-ui,sans-serif;background:#8B9E90;color:#F2F0E6;border:0;border-radius:999px;padding:12px 18px;box-shadow:0 4px 14px rgba(0,0,0,.2);cursor:pointer}
@media (max-width:767px){#jrb-avis-btn{bottom:92px;padding:10px 14px;font-size:13px}}
#jrb-fond{position:fixed;inset:0;z-index:2147483100;background:rgba(0,0,0,.5);display:none;align-items:flex-end;justify-content:center}
#jrb-fond.on{display:flex}
#jrb-fen{background:#F2F0E6;color:#2D2D2D;font-family:Chillax,system-ui,sans-serif;width:100%;max-width:480px;border-radius:22px 22px 0 0;padding:18px;max-height:92vh;overflow:auto}
@media (min-width:768px){#jrb-fond{align-items:center}#jrb-fen{border-radius:22px}}
#jrb-fen h2{margin:0 0 4px;font-size:20px}
#jrb-fen p{margin:0 0 10px;font-size:13px;color:#6B6B6B}
#jrb-fen select,#jrb-fen textarea{width:100%;font:inherit;font-size:16px;border:1.5px solid #E0DDD5;border-radius:14px;padding:10px 12px;background:#fff;color:#2D2D2D;margin-bottom:10px}
#jrb-fen textarea{min-height:110px;resize:vertical}
#jrb-fen .ligne{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-bottom:10px}
#jrb-fen button{font:600 14px Chillax,system-ui,sans-serif;border-radius:999px;padding:11px 18px;cursor:pointer;border:0}
#jrb-envoyer{background:#8B9E90;color:#F2F0E6}
#jrb-fermer,#jrb-capt{background:transparent;color:#2D2D2D;box-shadow:inset 0 0 0 2px #2D2D2D}
#jrb-etat{font-weight:600;min-height:1.3em;font-size:13px}
#jrb-vignette{max-width:100%;max-height:120px;border-radius:10px;display:none}
.jrb-simule{background:#E8D5C4;color:#2D2D2D;border-radius:12px;padding:8px 12px;font:700 12px Chillax,system-ui,sans-serif;margin:8px 0;text-align:center}
#jrb-activite{position:fixed;left:14px;bottom:14px;z-index:2147482000;max-width:300px;font:12px Chillax,system-ui,sans-serif;background:#F8F7F1;border:1px solid #E0DDD5;border-radius:14px;padding:8px 12px;display:none}
@media (min-width:768px){#jrb-activite.on{display:block}}
+149
Voir le fichier
@@ -0,0 +1,149 @@
/* Couche bêta JobRunner : bandeau, « Donner mon avis », données de démo (bots), libellés SIMULÉ.
Injectée par beta/server.py : le site d'origine n'est pas modifié. */
(function () {
'use strict';
var H = { 'Content-Type': 'application/json', 'X-Beta': '1' };
function el(tag, attrs, html) { var e = document.createElement(tag); for (var k in attrs || {}) e.setAttribute(k, attrs[k]); if (html != null) e.textContent = html; return e; }
// --- Bandeau Bêta ---
var b = el('div', { id: 'jrb-bandeau', role: 'status' });
var badge = el('b', {}, 'BÊTA'); b.appendChild(badge);
b.appendChild(document.createTextNode('Données fictives · paiement SIMULÉ'));
var out = el('a', { href: '#' }, 'Quitter'); b.appendChild(out);
out.addEventListener('click', function (ev) {
ev.preventDefault();
fetch('/__beta/logout', { method: 'POST', headers: { 'X-Beta': '1' }, credentials: 'same-origin' })
.then(function () { location.href = '/__beta/gate'; }, function () { location.href = '/__beta/gate'; });
});
document.body.insertBefore(b, document.body.firstChild);
// --- Garde-fou paiement : aucun appel vers un prestataire de paiement ---
var BLOC = /stripe|stancer|paypal|adyen|checkout|didit/i;
var f0 = window.fetch;
if (f0) window.fetch = function (u) { if (BLOC.test(String(u && u.url || u))) return Promise.reject(new Error('Paiement désactivé en bêta')); return f0.apply(this, arguments); };
// --- Libellés SIMULÉ ---
var tcm = window.triggerCustomModal;
if (typeof tcm === 'function') window.triggerCustomModal = function (msg) {
if (typeof msg === 'string' && /séquestre|débloqu|versé|virement|paiement|pass/i.test(msg) && !/SIMUL/.test(msg)) arguments[0] = msg + ' (SIMULÉ)';
return tcm.apply(this, arguments);
};
function marquer(id, texte) {
var m = document.getElementById(id); if (!m || m.querySelector('.jrb-simule')) return;
var n = el('div', { 'class': 'jrb-simule' }, texte);
var cible = m.firstElementChild || m; cible.insertBefore(n, cible.firstChild);
}
function simules() {
marquer('escrow-confirm-modal', 'SIMULÉ · aucun argent réel · paiement Stancer non branché');
marquer('legal-sheet', 'SIMULÉ · aucun paiement réel ne sera effectué');
}
// --- Données de démo (bots) ---
var vus = {};
function categorie(id) { return ((typeof categoriesData !== "undefined" ? categoriesData : []) || []).filter(function (c) { return c.id === id; })[0] || { id: id, name: id, icon: 'ph-hammer' }; }
function fusion(d) {
var pro = {}; d.profiles.forEach(function (p) { pro[p.id] = p; });
var neuf = false;
var modele = (runners || [])[0] || {};
d.ads.forEach(function (a) {
var k = 'a' + a.id; if (vus[k]) return; var p = pro[a.profile_id]; if (!p) return; vus[k] = 1; neuf = true;
var c = categorie(a.category), nom = p.first + ' ' + p.last_initial + '. (fictif)';
var ref = (runners || []).filter(function (r) { return r.categoryId === a.category; })[0] || modele;
runners.push({
id: 900000 + a.id, name: nom, firstName: p.first, lastName: p.last_initial, fullName: nom, title: a.title,
categoryId: c.id, categoryName: c.name, categoryIcon: c.icon, rating: '4.5', reviews: 0, reviewsList: [],
price: a.price, time: a.unit, passType: 'lite', sellerType: 'particulier', isRecommended: false,
city: p.city, cluster: p.city, department: p.dept, region: p.region, distanceKm: 3, location: p.city + ' (3 km)',
avatar: '/__beta/avatar/' + p.seed + '.svg', jobImage: ref.jobImage, hasShort: false, shortVideo: null, likes: 0,
desc: '[PROFIL FICTIF] ' + a.descr, isDemo: true
});
});
d.convs.forEach(function (cv) {
var p = pro[cv.profile_id]; if (!p) return;
var id = 900000 + cv.id, existante = conversations.filter(function (x) { return x.id === id; })[0];
var nom = p.first + ' ' + p.last_initial + '. (fictif)';
if (!existante) {
existante = { id: id, runnerId: 0, name: nom, avatar: '/__beta/avatar/' + p.seed + '.svg', lastMsg: '', time: "À l'instant",
timestamp: Date.now(), unread: true, messages: [], demoCount: 0, isDemo: true };
if (cv.status === 'proposed') existante.contract = { status: 'proposed', title: cv.title, amount: cv.amount,
runnerAccepted: true, clientAccepted: false, runnerDone: false, clientDone: false };
conversations.unshift(existante); neuf = true;
}
cv.messages.slice(existante.demoCount).forEach(function (m) {
existante.messages.push({ sender: m.sender === 'me' ? 'me' : 'them', text: m.text });
existante.lastMsg = m.text; existante.unread = true; existante.timestamp = Date.now(); neuf = true;
});
existante.demoCount = cv.messages.length;
});
var a = document.getElementById('jrb-activite');
if (a && d.activity.length) { a.textContent = ''; a.appendChild(el('b', {}, 'Activité des bots')); d.activity.slice(0, 4).forEach(function (x) { a.appendChild(el('div', {}, '• ' + x.text)); }); a.className = 'on'; }
if (neuf) rafraichir();
}
function rafraichir() {
try {
if (typeof window.updateHomeRecs === 'function') window.updateHomeRecs();
if (typeof window.displaySearchResults === 'function') window.displaySearchResults(runners, 'Toutes les annonces');
if (typeof window.sortConversations === 'function') window.sortConversations();
if (typeof window.renderMessagesList === 'function') window.renderMessagesList();
if (typeof window.updateMessagesNotification === 'function') window.updateMessagesNotification();
} catch (e) { /* l'application reste utilisable sans la démo */ }
}
function charger() {
if (typeof runners === "undefined" || typeof conversations === "undefined") return;
fetch('/__beta/api/demo', { credentials: 'same-origin' }).then(function (r) { return r.ok ? r.json() : null; }).then(function (d) { if (d) fusion(d); }).catch(function () {});
}
// --- « Donner mon avis » ---
var cap = null;
var btn = el('button', { id: 'jrb-avis-btn', type: 'button' }, 'Donner mon avis');
var fond = el('div', { id: 'jrb-fond' });
var fen = el('div', { id: 'jrb-fen', role: 'dialog', 'aria-modal': 'true', 'aria-labelledby': 'jrb-t' });
fen.innerHTML = '<h2 id="jrb-t">Votre avis</h2><p>Dites-nous ce qu\'il faut garder ou changer sur cette page. Vos retours restent dans la bêta.</p>' +
'<select id="jrb-kind" aria-label="Type de retour"><option value="changer">À changer</option><option value="garder">À garder</option><option value="bug">Problème / bug</option><option value="autre">Autre</option></select>' +
'<textarea id="jrb-txt" maxlength="4000" placeholder="Votre message" aria-label="Votre message"></textarea>' +
'<div class="ligne"><label style="font-size:13px">Capture (facultatif) <input id="jrb-file" type="file" accept="image/png,image/jpeg,image/webp"></label>' +
'<button id="jrb-capt" type="button">Capturer l\'écran</button></div><img id="jrb-vignette" alt="Aperçu de la capture">' +
'<div class="ligne"><button id="jrb-envoyer" type="button">Envoyer</button><button id="jrb-fermer" type="button">Annuler</button></div><div id="jrb-etat" role="status"></div>';
fond.appendChild(fen);
var act = el('div', { id: 'jrb-activite' });
document.body.appendChild(btn); document.body.appendChild(fond); document.body.appendChild(act);
function $(i) { return document.getElementById(i); }
function ouvrir() { fond.className = 'on'; $('jrb-etat').textContent = ''; $('jrb-txt').focus(); }
function fermer() { fond.className = ''; cap = null; $('jrb-vignette').style.display = 'none'; $('jrb-txt').value = ''; $('jrb-file').value = ''; }
btn.onclick = ouvrir; $('jrb-fermer').onclick = fermer;
document.addEventListener('keydown', function (e) { if (e.key === 'Escape' && fond.className) fermer(); });
function reduire(src, cb) {
var im = new Image(); im.onload = function () {
var w = Math.min(1280, im.width), h = Math.round(im.height * w / im.width), c = document.createElement('canvas'); c.width = w; c.height = h;
c.getContext('2d').drawImage(im, 0, 0, w, h); cb(c.toDataURL('image/jpeg', 0.7));
}; im.src = src;
}
function pose(data) { cap = data; var v = $('jrb-vignette'); v.src = data; v.style.display = 'block'; }
$('jrb-file').onchange = function () {
var f = this.files[0]; if (!f) return; var r = new FileReader();
r.onload = function () { reduire(r.result, pose); }; r.readAsDataURL(f);
};
$('jrb-capt').onclick = function () { // capture d'écran navigateur (si pris en charge)
if (!navigator.mediaDevices || !navigator.mediaDevices.getDisplayMedia) { $('jrb-etat').textContent = 'Capture non disponible ici : joignez une image.'; return; }
fond.style.visibility = 'hidden';
navigator.mediaDevices.getDisplayMedia({ video: true, preferCurrentTab: true }).then(function (s) {
var v = document.createElement('video'); v.srcObject = s;
v.onloadedmetadata = function () { v.play().then(function () { setTimeout(function () {
var c = document.createElement('canvas'); c.width = v.videoWidth; c.height = v.videoHeight; c.getContext('2d').drawImage(v, 0, 0);
s.getTracks().forEach(function (t) { t.stop(); }); fond.style.visibility = ''; reduire(c.toDataURL('image/png'), pose); }, 300); }); };
}).catch(function () { fond.style.visibility = ''; $('jrb-etat').textContent = 'Capture annulée.'; });
};
$('jrb-envoyer').onclick = function () {
var t = $('jrb-txt').value.trim(); var st = $('jrb-etat');
if (t.length < 3) { st.textContent = 'Écrivez quelques mots.'; return; }
this.disabled = true; var me = this;
fetch('/__beta/api/feedback', { method: 'POST', headers: H, credentials: 'same-origin', body: JSON.stringify({
text: t, kind: $('jrb-kind').value, page: location.pathname + location.hash, viewport: innerWidth + 'x' + innerHeight, screenshot: cap }) })
.then(function (r) { return r.json().then(function (d) { return [r.ok, d]; }); })
.then(function (x) { me.disabled = false; if (x[0]) { st.textContent = 'Merci ! Retour enregistré.'; setTimeout(fermer, 1200); } else st.textContent = x[1].erreur || 'Échec.'; })
.catch(function () { me.disabled = false; st.textContent = 'Connexion impossible.'; });
};
window.addEventListener('load', function () { simules(); charger(); setInterval(function () { simules(); charger(); }, 20000); });
document.addEventListener('click', function () { setTimeout(simules, 50); }, true);
})();
+1002
Voir le fichier
Diff désactivé car ce fichier est trop long. Voir la Diff
+704
Voir le fichier
@@ -0,0 +1,704 @@
<!doctype html>
<html lang="fr">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="robots" content="noindex,nofollow">
<title>JobRunner bêta · accès testeurs</title>
<link rel="icon" type="image/png" href="../../assets/img/logo.png">
<link rel="stylesheet" href="https://api.fontshare.com/v2/css?f[]=chillax@400,600,700&display=swap">
<style>
@font-face {
font-family: 'Chillax';
font-weight: 400;
font-style: normal;
font-display: swap;
src: url('/assets/fonts/chillax-latin-400-normal.woff2') format('woff2'),
url('../../assets/fonts/chillax-latin-400-normal.woff2') format('woff2');
}
@font-face {
font-family: 'Chillax';
font-weight: 700;
font-style: normal;
font-display: swap;
src: url('/assets/fonts/chillax-latin-700-normal.woff2') format('woff2'),
url('../../assets/fonts/chillax-latin-700-normal.woff2') format('woff2');
}
/* Pages de la bêta hors application (porte d'entrée, formulaire) : charte JobRunner */
:root {
--fond: #F2F0E6;
--sauge: #8B9E90;
--sauge-sombre: #6E8173;
--sauge-clair: #D8E0DA;
--sauge-fond: #EBF0EC;
--texte: #2D2D2D;
--texte-doux: #5A5A5A;
--texte-muet: #7A7A7A;
--chair: #E8D5C4;
--chair-clair: #F6EDE5;
--filet: #E0DDD5;
--filet-fort: #CEC9BD;
--carte: #FFFFFF;
--carte-teintee: #F8F7F1;
--ombre: 0 10px 30px -10px rgba(45, 45, 45, 0.08), 0 2px 6px -1px rgba(45, 45, 45, 0.04);
--ombre-carte: 0 16px 40px -12px rgba(45, 45, 45, 0.12);
--rayon-xl: 28px;
--rayon-lg: 20px;
--rayon-md: 14px;
--rayon-sm: 10px;
}
* {
box-sizing: border-box;
}
html, body {
margin: 0;
padding: 0;
background-color: var(--fond);
color: var(--texte);
font-family: 'Chillax', 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
line-height: 1.55;
-webkit-font-smoothing: antialiased;
color-scheme: light;
}
a {
color: var(--sauge-sombre);
text-decoration: none;
font-weight: 600;
transition: color 0.2s ease;
}
a:hover {
color: var(--texte);
text-decoration: underline;
}
/* Conteneurs */
main {
max-width: 760px;
margin: 0 auto;
padding: 40px 20px 80px;
}
main.centre {
max-width: 480px;
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 16px;
padding: 32px 20px;
margin: 0 auto;
text-align: center;
}
/* Rétro-compatibilité pour gate.html */
.chapo {
color: var(--texte-doux);
max-width: 460px;
margin: 0 0 10px;
}
.logo {
border-radius: 20px;
box-shadow: 0 8px 20px -6px rgba(45, 45, 45, 0.15);
}
.badge {
display: inline-flex;
font-size: 13px;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
padding: 6px 14px;
border-radius: 999px;
background: var(--sauge);
color: #FFFFFF;
}
.carte {
background: var(--carte);
border: 1.5px solid var(--filet);
border-radius: var(--rayon-lg);
padding: 24px;
width: 100%;
max-width: 460px;
text-align: left;
box-shadow: var(--ombre);
}
#code {
text-align: center;
letter-spacing: 0.1em;
font-weight: 700;
font-size: 18px;
text-transform: uppercase;
}
.btn {
font: inherit;
font-weight: 700;
font-size: 15px;
border: 0;
border-radius: 999px;
padding: 13px 26px;
cursor: pointer;
margin-top: 16px;
width: 100%;
transition: all 0.2s ease;
}
.btn-primaire {
background: var(--sauge);
color: #FFFFFF;
}
.btn-primaire:hover {
background: var(--sauge-sombre);
transform: translateY(-1px);
}
.btn:disabled {
opacity: 0.6;
cursor: wait;
}
.erreur {
color: #A0554B;
font-weight: 600;
min-height: 1.4em;
margin: 10px 0 0;
}
.petit {
font-size: 13px;
color: var(--texte-doux);
max-width: 460px;
}
/* En-tête de marque */
.entete-marque {
display: flex;
flex-direction: column;
align-items: center;
text-align: center;
margin-bottom: 32px;
}
.logo-wrap {
position: relative;
margin-bottom: 14px;
}
.logo-wrap img {
border-radius: 22px;
box-shadow: 0 8px 20px -6px rgba(45, 45, 45, 0.15);
display: block;
}
.badge-beta {
display: inline-flex;
align-items: center;
gap: 6px;
font-size: 12px;
font-weight: 700;
letter-spacing: 0.08em;
text-transform: uppercase;
padding: 5px 14px;
border-radius: 999px;
background-color: var(--sauge);
color: #FFFFFF;
margin-bottom: 12px;
}
.badge-beta i {
width: 6px;
height: 6px;
border-radius: 50%;
background-color: #FFFFFF;
display: inline-block;
}
h1 {
font-size: clamp(28px, 5vw, 38px);
font-weight: 800;
line-height: 1.15;
margin: 6px 0 10px;
letter-spacing: -0.02em;
}
.sous-titre {
color: var(--texte-doux);
font-size: clamp(15px, 2.5vw, 17px);
max-width: 580px;
margin: 0 auto;
line-height: 1.5;
}
/* Bannière d'avantages testeurs */
.avantages-grille {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
gap: 14px;
margin: 28px 0 32px;
}
.avantage-carte {
background: var(--carte);
border: 1px solid var(--filet);
border-radius: var(--rayon-md);
padding: 16px 18px;
display: flex;
align-items: flex-start;
gap: 12px;
box-shadow: var(--ombre);
}
.avantage-ico {
font-size: 22px;
line-height: 1;
background: var(--sauge-fond);
padding: 8px;
border-radius: 12px;
flex-shrink: 0;
}
.avantage-texte strong {
display: block;
font-size: 14px;
font-weight: 700;
color: var(--texte);
margin-bottom: 2px;
}
.avantage-texte span {
font-size: 13px;
color: var(--texte-doux);
line-height: 1.35;
display: block;
}
/* Carte Formulaire */
.carte-form {
background: var(--carte);
border: 1.5px solid var(--filet);
border-radius: var(--rayon-xl);
padding: 36px 32px;
box-shadow: var(--ombre-carte);
position: relative;
}
@media (max-width: 600px) {
.carte-form {
padding: 24px 18px;
border-radius: var(--rayon-lg);
}
}
.form-section {
margin-bottom: 28px;
}
.form-section-titre {
font-size: 15px;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.06em;
color: var(--sauge-sombre);
margin: 0 0 16px 0;
display: flex;
align-items: center;
gap: 8px;
}
.form-section-titre span.numero {
width: 24px;
height: 24px;
border-radius: 50%;
background: var(--sauge);
color: #fff;
font-size: 12px;
display: inline-grid;
place-items: center;
font-weight: 800;
}
.champs-grille {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
}
@media (max-width: 580px) {
.champs-grille {
grid-template-columns: 1fr;
gap: 12px;
}
}
.champ {
display: flex;
flex-direction: column;
margin-bottom: 14px;
}
.champ label {
font-size: 13.5px;
font-weight: 700;
margin-bottom: 6px;
color: var(--texte);
display: flex;
justify-content: space-between;
align-items: center;
}
.champ label .aide {
font-size: 12px;
font-weight: 400;
color: var(--texte-muet);
}
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"] {
width: 100%;
font-family: inherit;
font-size: 15px;
padding: 13px 16px;
border: 1.5px solid var(--filet);
border-radius: var(--rayon-md);
background-color: #FAFAFA;
color: var(--texte);
outline: none;
transition: all 0.2s ease;
}
input:hover {
border-color: var(--filet-fort);
}
input:focus {
background-color: #FFFFFF;
border-color: var(--sauge);
box-shadow: 0 0 0 3px rgba(139, 158, 144, 0.25);
}
/* Bloc parent pour mineurs */
.bloc-parent {
background: var(--chair-clair);
border: 1.5px solid var(--chair);
border-radius: var(--rayon-md);
padding: 20px;
margin: 16px 0;
transition: all 0.3s ease;
}
.bloc-parent.cache {
display: none;
}
.bloc-parent-titre {
font-size: 14px;
font-weight: 700;
margin: 0 0 6px 0;
color: #7D5D44;
}
.bloc-parent-desc {
font-size: 13px;
color: #7D5D44;
margin: 0 0 14px 0;
}
/* Cartes de consentement tactiles */
.options-liste {
display: flex;
flex-direction: column;
gap: 10px;
}
.option-carte {
display: flex;
align-items: flex-start;
gap: 14px;
background: var(--carte-teintee);
border: 1.5px solid var(--filet);
border-radius: var(--rayon-md);
padding: 14px 16px;
cursor: pointer;
transition: all 0.2s ease;
user-select: none;
}
.option-carte:hover {
border-color: var(--sauge);
background: #FFFFFF;
}
.option-carte:has(input:checked) {
border-color: var(--sauge);
background: var(--sauge-fond);
}
.option-carte input[type="checkbox"] {
appearance: none;
-webkit-appearance: none;
width: 22px;
height: 22px;
border: 2px solid var(--filet-fort);
border-radius: 7px;
background: #FFFFFF;
margin: 2px 0 0 0;
flex-shrink: 0;
cursor: pointer;
display: grid;
place-content: center;
transition: all 0.2s ease;
}
.option-carte input[type="checkbox"]:checked {
background: var(--sauge);
border-color: var(--sauge);
}
.option-carte input[type="checkbox"]:checked::before {
content: "";
width: 10px;
height: 6px;
border-left: 2px solid #FFFFFF;
border-bottom: 2px solid #FFFFFF;
transform: rotate(-45deg) translate(1px, -1px);
}
.option-texte {
font-size: 13.5px;
line-height: 1.45;
color: var(--texte);
}
.option-texte strong {
display: block;
font-weight: 700;
margin-bottom: 2px;
}
.option-texte span {
color: var(--texte-doux);
font-size: 12.5px;
}
/* Réseaux sociaux */
.reseaux-suivi {
display: flex;
align-items: center;
gap: 10px;
flex-wrap: wrap;
margin-top: 10px;
}
.reseau-chip {
display: inline-flex;
align-items: center;
gap: 6px;
background: #FFFFFF;
border: 1.5px solid var(--filet);
border-radius: 999px;
padding: 6px 14px;
font-size: 13px;
font-weight: 600;
color: var(--texte);
text-decoration: none;
transition: all 0.2s ease;
}
.reseau-chip:hover {
border-color: var(--sauge);
color: var(--sauge-sombre);
transform: translateY(-1px);
text-decoration: none;
}
/* Boutons */
.btn-soumettre {
font-family: inherit;
font-size: 16px;
font-weight: 700;
background-color: var(--sauge);
color: #FFFFFF;
border: none;
border-radius: 999px;
padding: 16px 32px;
width: 100%;
cursor: pointer;
margin-top: 24px;
box-shadow: 0 8px 20px -4px rgba(139, 158, 144, 0.4);
transition: all 0.2s ease;
display: flex;
align-items: center;
justify-content: center;
gap: 10px;
}
.btn-soumettre:hover {
background-color: var(--sauge-sombre);
transform: translateY(-2px);
box-shadow: 0 12px 24px -6px rgba(139, 158, 144, 0.5);
}
.btn-soumettre:active {
transform: translateY(0);
}
.btn-soumettre:disabled {
opacity: 0.6;
cursor: not-allowed;
transform: none;
}
/* Écran de succès */
.succes-carte {
text-align: center;
padding: 40px 20px;
}
.succes-icone {
width: 72px;
height: 72px;
border-radius: 50%;
background: var(--sauge-fond);
color: var(--sauge);
display: inline-grid;
place-items: center;
font-size: 36px;
margin-bottom: 20px;
}
.succes-carte h2 {
font-size: 26px;
font-weight: 800;
margin: 0 0 10px 0;
}
.succes-carte p {
color: var(--texte-doux);
font-size: 15px;
max-width: 480px;
margin: 0 auto 28px;
line-height: 1.5;
}
.succes-actions {
display: flex;
flex-direction: column;
gap: 12px;
max-width: 380px;
margin: 0 auto;
}
.btn-secondaire {
font-family: inherit;
font-size: 15px;
font-weight: 700;
background: #FFFFFF;
color: var(--texte);
border: 1.5px solid var(--filet);
border-radius: 999px;
padding: 13px 24px;
display: inline-flex;
align-items: center;
justify-content: center;
gap: 8px;
text-decoration: none;
transition: all 0.2s ease;
}
.btn-secondaire:hover {
border-color: var(--texte);
text-decoration: none;
}
/* Pied de page */
.pied-form {
text-align: center;
margin-top: 32px;
color: var(--texte-muet);
font-size: 13.5px;
}
.pied-form a {
color: var(--texte-doux);
}
.pied-form a:hover {
color: var(--texte);
}
.message-alerte {
padding: 12px 16px;
border-radius: var(--rayon-md);
font-size: 14px;
font-weight: 600;
margin-top: 14px;
display: none;
}
.message-alerte.erreur {
background: #FDF2F0;
color: #A0554B;
border: 1px solid #F5D6D1;
display: block;
}
.piege-robot {
position: absolute;
left: -9999px;
height: 0;
overflow: hidden;
}
</style>
</head>
<body>
<main class="centre">
<img id="logo-gate" class="logo" src="../../assets/img/logo.png" alt="JobRunner" width="88" height="88">
<span class="badge">Bêta · version de test</span>
<h1>Accès testeurs</h1>
<p class="chapo">Entrez le code que JobRunner vous a communiqué. Tout ce que vous verrez ici est fictif : profils, annonces et paiements sont <b>simulés</b>.</p>
<form id="f" class="carte" autocomplete="off" novalidate>
<label for="code">Votre code d'accès</label>
<input id="code" name="code" type="text" inputmode="text" autocapitalize="characters" spellcheck="false" placeholder="JRB-XXXX-XXXX-XXXX" maxlength="24" required>
<button class="btn btn-primaire" type="submit">Entrer</button>
<p id="msg" class="erreur" role="alert" aria-live="polite"></p>
</form>
<p class="petit">Pas encore de code ? <a href="/__beta/formulaire">Remplissez le formulaire testeur</a> ou téléchargez le <a href="/__beta/static/pdf/formulaire-testeur-jobrunner.pdf">formulaire PDF</a>.</p>
</main>
<script>
(function() {
const logo = document.getElementById('logo-gate');
const b64Logo = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAhoAAAIaCAYAAABmueQmAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAPZgSURBVHhe7P2FdyTXtf4P3z/gfdfv+/7uDdmDGjFLI81omJmZmTTMDGKpJbWYYciexE7MjhM7iRPbiWNmz4zt2Ik537tiCtzrAdvZ73l21emqLlWLRpoR7GetZzVVF3X12Z86sM9/iEQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUQikUgkEolEIpFIJBKJRCKRSCQSiUSdqg8+uHjvyy8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+SVZ1N5fRHNXDiFQqMHUEh4X6qpKxbYEIlEIpGoq6g50NC1Gp0FGrAbaGjrZTAvih00UKuRU5HNuTZyy7IovzKXlq1bSIMi+lJkfDAVFmUKbIhEIpFI1BXUsaChgcJpAzDcQAP21ha4Wq8X28Y+WKCRY+xjZQ7vE4a9Ipvoqi0raUBkfx6RsufQNoENkUgkEolutTq26cSCB3/7g4bzc6zTDhh4DWObGjLsoIE+JFmYVl59F9CCESoYCptX5aGFaxcybARHD6T03GMCGyKRSCQS3Up1bGdQf4BoChja/stpsHC6ANs0t20HjuwqtX/m1PXGcw9lVmRRfp1XfZ5P63etpyAFGqHRQXT42F6BDZFIJBKJbpU0aGB4K0ACzREBQUO50BUwtP0Bwh0yYP/lnIDhq9VQ67RvzwccCjByqrMVXGRQQUM+ZVXlUE5NHmFUirexRC1bSFsPbqX4lBhOr75x8wr64IPLkmdDJBKJRKKbrXUbV1C/4NuMGg0V3Hn4aFU2N1Gg1gBm2FAuUO9Zgd8fFtztBhludvsu7AIZaMYx9yfPZ2M/DXs44ReOZfexHRSdFEZhMYModft6qdkQiUQikehma92WVVyjgcygqNHAaA7UFmjQQO2BDuyF6jXsDgVudoMKN7t9F247aGB/AUsYtVJ1voL2n9pD46aNppCogbRs5QJ6/c3nBDhEIpFIJLpZAmigeeHAqf1U0lBk1GiYCbJ0kNdNGF0BNNgmaOjOqnYoYjCq8XC68oyiNJ5m/kT2YRo3ZQRFxofS/EXT6fXXnxXYEIlEIpHoZmjjtrUUHDmADqUf5KnYjWGlRspv3+yqfqCBwO8GBW52gwo3u30Xbhk00JfEr/al3pgXBX1NML08ammqz1dQtjeNkkclUkTcIJq3YCq9++fX3jNPgUgkEolEos7ShtR1vhqN8sYyKqorss0/YoCG13RRrQEd7lDQFrcNNPwgww4a5igUJ2jg0Xu6kMrOlvJsr7nl2VyzkV2SQZNmYZr5EJo5ZyI98ftH6cq1L0+Yp0IkEolEIlLigne tronquée
if (logo) {
if (location.protocol === 'http:' || location.protocol === 'https:') {
logo.src = '/assets/img/logo.png';
}
logo.onerror = function() {
this.onerror = null;
this.src = b64Logo;
};
}
const f = document.getElementById('f'), m = document.getElementById('msg'), i = document.getElementById('code');
f.addEventListener('submit', async e => {
e.preventDefault(); m.textContent = ''; const b = f.querySelector('button'); b.disabled = true;
try {
const r = await fetch('/__beta/api/enter', {
method: 'POST',
headers: {'Content-Type': 'application/json', 'X-Beta': '1'},
body: JSON.stringify({code: i.value})
});
const d = await r.json().catch(() => ({}));
if (r.ok && d.ok) { location.href = d.suite || '/app.html'; return; }
m.textContent = d.erreur || 'Accès refusé.';
} catch (_) {
m.textContent = 'Connexion impossible. Réessayez.';
}
b.disabled = false;
});
})();
</script>
</body>
</html>
+625
Voir le fichier
@@ -0,0 +1,625 @@
/* Pages de la bêta hors application (porte d'entrée, formulaire) : charte JobRunner */
:root {
--fond: #F2F0E6;
--sauge: #8B9E90;
--sauge-sombre: #6E8173;
--sauge-clair: #D8E0DA;
--sauge-fond: #EBF0EC;
--texte: #2D2D2D;
--texte-doux: #5A5A5A;
--texte-muet: #7A7A7A;
--chair: #E8D5C4;
--chair-clair: #F6EDE5;
--filet: #E0DDD5;
--filet-fort: #CEC9BD;
--carte: #FFFFFF;
--carte-teintee: #F8F7F1;
--ombre: 0 10px 30px -10px rgba(45, 45, 45, 0.08), 0 2px 6px -1px rgba(45, 45, 45, 0.04);
--ombre-carte: 0 16px 40px -12px rgba(45, 45, 45, 0.12);
--rayon-xl: 28px;
--rayon-lg: 20px;
--rayon-md: 14px;
--rayon-sm: 10px;
}
* {
box-sizing: border-box;
}
html, body {
margin: 0;
padding: 0;
background-color: var(--fond);
color: var(--texte);
font-family: 'Chillax', 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
line-height: 1.55;
-webkit-font-smoothing: antialiased;
color-scheme: light;
}
a {
color: var(--sauge-sombre);
text-decoration: none;
font-weight: 600;
transition: color 0.2s ease;
}
a:hover {
color: var(--texte);
text-decoration: underline;
}
/* Conteneurs */
main {
max-width: 760px;
margin: 0 auto;
padding: 40px 20px 80px;
}
main.centre {
max-width: 480px;
min-height: 100vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 16px;
padding: 32px 20px;
margin: 0 auto;
text-align: center;
}
/* Rétro-compatibilité pour gate.html */
.chapo {
color: var(--texte-doux);
max-width: 460px;
margin: 0 0 10px;
}
.logo {
border-radius: 20px;
box-shadow: 0 8px 20px -6px rgba(45, 45, 45, 0.15);
}
.badge {
display: inline-flex;
font-size: 13px;
font-weight: 700;
letter-spacing: 0.06em;
text-transform: uppercase;
padding: 6px 14px;
border-radius: 999px;
background: var(--sauge);
color: #FFFFFF;
}
.carte {
background: var(--carte);
border: 1.5px solid var(--filet);
border-radius: var(--rayon-lg);
padding: 24px;
width: 100%;
max-width: 460px;
text-align: left;
box-shadow: var(--ombre);
}
#code {
text-align: center;
letter-spacing: 0.1em;
font-weight: 700;
font-size: 18px;
text-transform: uppercase;
}
.btn {
font: inherit;
font-weight: 700;
font-size: 15px;
border: 0;
border-radius: 999px;
padding: 13px 26px;
cursor: pointer;
margin-top: 16px;
width: 100%;
transition: all 0.2s ease;
}
.btn-primaire {
background: var(--sauge);
color: #FFFFFF;
}
.btn-primaire:hover {
background: var(--sauge-sombre);
transform: translateY(-1px);
}
.btn:disabled {
opacity: 0.6;
cursor: wait;
}
.erreur {
color: #A0554B;
font-weight: 600;
min-height: 1.4em;
margin: 10px 0 0;
}
.petit {
font-size: 13px;
color: var(--texte-doux);
max-width: 460px;
}
/* En-tête de marque */
.entete-marque {
display: flex;
flex-direction: column;
align-items: center;
text-align: center;
margin-bottom: 32px;
}
.logo-wrap {
position: relative;
margin-bottom: 14px;
}
.logo-wrap img {
border-radius: 22px;
box-shadow: 0 8px 20px -6px rgba(45, 45, 45, 0.15);
display: block;
}
.badge-beta {
display: inline-flex;
align-items: center;
gap: 6px;
font-size: 12px;
font-weight: 700;
letter-spacing: 0.08em;
text-transform: uppercase;
padding: 5px 14px;
border-radius: 999px;
background-color: var(--sauge);
color: #FFFFFF;
margin-bottom: 12px;
}
.badge-beta i {
width: 6px;
height: 6px;
border-radius: 50%;
background-color: #FFFFFF;
display: inline-block;
}
h1 {
font-size: clamp(28px, 5vw, 38px);
font-weight: 800;
line-height: 1.15;
margin: 6px 0 10px;
letter-spacing: -0.02em;
}
.sous-titre {
color: var(--texte-doux);
font-size: clamp(15px, 2.5vw, 17px);
max-width: 580px;
margin: 0 auto;
line-height: 1.5;
}
/* Bannière d'avantages testeurs */
.avantages-grille {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
gap: 14px;
margin: 28px 0 32px;
}
.avantage-carte {
background: var(--carte);
border: 1px solid var(--filet);
border-radius: var(--rayon-md);
padding: 16px 18px;
display: flex;
align-items: flex-start;
gap: 12px;
box-shadow: var(--ombre);
}
.avantage-ico {
font-size: 22px;
line-height: 1;
background: var(--sauge-fond);
padding: 8px;
border-radius: 12px;
flex-shrink: 0;
}
.avantage-texte strong {
display: block;
font-size: 14px;
font-weight: 700;
color: var(--texte);
margin-bottom: 2px;
}
.avantage-texte span {
font-size: 13px;
color: var(--texte-doux);
line-height: 1.35;
display: block;
}
/* Carte Formulaire */
.carte-form {
background: var(--carte);
border: 1.5px solid var(--filet);
border-radius: var(--rayon-xl);
padding: 36px 32px;
box-shadow: var(--ombre-carte);
position: relative;
}
@media (max-width: 600px) {
.carte-form {
padding: 24px 18px;
border-radius: var(--rayon-lg);
}
}
.form-section {
margin-bottom: 28px;
}
.form-section-titre {
font-size: 15px;
font-weight: 700;
text-transform: uppercase;
letter-spacing: 0.06em;
color: var(--sauge-sombre);
margin: 0 0 16px 0;
display: flex;
align-items: center;
gap: 8px;
}
.form-section-titre span.numero {
width: 24px;
height: 24px;
border-radius: 50%;
background: var(--sauge);
color: #fff;
font-size: 12px;
display: inline-grid;
place-items: center;
font-weight: 800;
}
.champs-grille {
display: grid;
grid-template-columns: 1fr 1fr;
gap: 16px;
}
@media (max-width: 580px) {
.champs-grille {
grid-template-columns: 1fr;
gap: 12px;
}
}
.champ {
display: flex;
flex-direction: column;
margin-bottom: 14px;
}
.champ label {
font-size: 13.5px;
font-weight: 700;
margin-bottom: 6px;
color: var(--texte);
display: flex;
justify-content: space-between;
align-items: center;
}
.champ label .aide {
font-size: 12px;
font-weight: 400;
color: var(--texte-muet);
}
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"] {
width: 100%;
font-family: inherit;
font-size: 15px;
padding: 13px 16px;
border: 1.5px solid var(--filet);
border-radius: var(--rayon-md);
background-color: #FAFAFA;
color: var(--texte);
outline: none;
transition: all 0.2s ease;
}
input:hover {
border-color: var(--filet-fort);
}
input:focus {
background-color: #FFFFFF;
border-color: var(--sauge);
box-shadow: 0 0 0 3px rgba(139, 158, 144, 0.25);
}
/* Bloc parent pour mineurs */
.bloc-parent {
background: var(--chair-clair);
border: 1.5px solid var(--chair);
border-radius: var(--rayon-md);
padding: 20px;
margin: 16px 0;
transition: all 0.3s ease;
}
.bloc-parent.cache {
display: none;
}
.bloc-parent-titre {
font-size: 14px;
font-weight: 700;
margin: 0 0 6px 0;
color: #7D5D44;
}
.bloc-parent-desc {
font-size: 13px;
color: #7D5D44;
margin: 0 0 14px 0;
}
/* Cartes de consentement tactiles */
.options-liste {
display: flex;
flex-direction: column;
gap: 10px;
}
.option-carte {
display: flex;
align-items: flex-start;
gap: 14px;
background: var(--carte-teintee);
border: 1.5px solid var(--filet);
border-radius: var(--rayon-md);
padding: 14px 16px;
cursor: pointer;
transition: all 0.2s ease;
user-select: none;
}
.option-carte:hover {
border-color: var(--sauge);
background: #FFFFFF;
}
.option-carte:has(input:checked) {
border-color: var(--sauge);
background: var(--sauge-fond);
}
.option-carte input[type="checkbox"] {
appearance: none;
-webkit-appearance: none;
width: 22px;
height: 22px;
border: 2px solid var(--filet-fort);
border-radius: 7px;
background: #FFFFFF;
margin: 2px 0 0 0;
flex-shrink: 0;
cursor: pointer;
display: grid;
place-content: center;
transition: all 0.2s ease;
}
.option-carte input[type="checkbox"]:checked {
background: var(--sauge);
border-color: var(--sauge);
}
.option-carte input[type="checkbox"]:checked::before {
content: "";
width: 10px;
height: 6px;
border-left: 2px solid #FFFFFF;
border-bottom: 2px solid #FFFFFF;
transform: rotate(-45deg) translate(1px, -1px);
}
.option-texte {
font-size: 13.5px;
line-height: 1.45;
color: var(--texte);
}
.option-texte strong {
display: block;
font-weight: 700;
margin-bottom: 2px;
}
.option-texte span {
color: var(--texte-doux);
font-size: 12.5px;
}
/* Réseaux sociaux */
.reseaux-suivi {
display: flex;
align-items: center;
gap: 10px;
flex-wrap: wrap;
margin-top: 10px;
}
.reseau-chip {
display: inline-flex;
align-items: center;
gap: 6px;
background: #FFFFFF;
border: 1.5px solid var(--filet);
border-radius: 999px;
padding: 6px 14px;
font-size: 13px;
font-weight: 600;
color: var(--texte);
text-decoration: none;
transition: all 0.2s ease;
}
.reseau-chip:hover {
border-color: var(--sauge);
color: var(--sauge-sombre);
transform: translateY(-1px);
text-decoration: none;
}
/* Boutons */
.btn-soumettre {
font-family: inherit;
font-size: 16px;
font-weight: 700;
background-color: var(--sauge);
color: #FFFFFF;
border: none;
border-radius: 999px;
padding: 16px 32px;
width: 100%;
cursor: pointer;
margin-top: 24px;
box-shadow: 0 8px 20px -4px rgba(139, 158, 144, 0.4);
transition: all 0.2s ease;
display: flex;
align-items: center;
justify-content: center;
gap: 10px;
}
.btn-soumettre:hover {
background-color: var(--sauge-sombre);
transform: translateY(-2px);
box-shadow: 0 12px 24px -6px rgba(139, 158, 144, 0.5);
}
.btn-soumettre:active {
transform: translateY(0);
}
.btn-soumettre:disabled {
opacity: 0.6;
cursor: not-allowed;
transform: none;
}
/* Écran de succès */
.succes-carte {
text-align: center;
padding: 40px 20px;
}
.succes-icone {
width: 72px;
height: 72px;
border-radius: 50%;
background: var(--sauge-fond);
color: var(--sauge);
display: inline-grid;
place-items: center;
font-size: 36px;
margin-bottom: 20px;
}
.succes-carte h2 {
font-size: 26px;
font-weight: 800;
margin: 0 0 10px 0;
}
.succes-carte p {
color: var(--texte-doux);
font-size: 15px;
max-width: 480px;
margin: 0 auto 28px;
line-height: 1.5;
}
.succes-actions {
display: flex;
flex-direction: column;
gap: 12px;
max-width: 380px;
margin: 0 auto;
}
.btn-secondaire {
font-family: inherit;
font-size: 15px;
font-weight: 700;
background: #FFFFFF;
color: var(--texte);
border: 1.5px solid var(--filet);
border-radius: 999px;
padding: 13px 24px;
display: inline-flex;
align-items: center;
justify-content: center;
gap: 8px;
text-decoration: none;
transition: all 0.2s ease;
}
.btn-secondaire:hover {
border-color: var(--texte);
text-decoration: none;
}
/* Pied de page */
.pied-form {
text-align: center;
margin-top: 32px;
color: var(--texte-muet);
font-size: 13.5px;
}
.pied-form a {
color: var(--texte-doux);
}
.pied-form a:hover {
color: var(--texte);
}
.message-alerte {
padding: 12px 16px;
border-radius: var(--rayon-md);
font-size: 14px;
font-weight: 600;
margin-top: 14px;
display: none;
}
.message-alerte.erreur {
background: #FDF2F0;
color: #A0554B;
border: 1px solid #F5D6D1;
display: block;
}
.piege-robot {
position: absolute;
left: -9999px;
height: 0;
overflow: hidden;
}
+666
Voir le fichier
@@ -0,0 +1,666 @@
%PDF-1.4
%“Œ‹ž ReportLab Generated PDF document (opensource)
1 0 obj
<<
/F1 2 0 R /F2+0 53 0 R
>>
endobj
2 0 obj
<<
/BaseFont /Helvetica /Encoding /WinAnsiEncoding /Name /F1 /Subtype /Type1 /Type /Font
>>
endobj
3 0 obj
<<
/BitsPerComponent 8 /ColorSpace /DeviceRGB /Filter [ /ASCII85Decode /FlateDecode ] /Height 538 /Length 65745 /SMask 4 0 R
/Subtype /Image /Type /XObject /Width 538
>>
stream
Gb"-6LK@a4\[\2[i4$Gh]=CKQ'mc8L$lq`u&4-hKU#$1B%FbsqR$gn8Pj*T#<,AH[/kOi^fT&V[Rk/d(G-#6Qf"GtC]s.RJI.'7G(l!T-J3X5-qlG"d)Bfr0%d33A]XtiRHf%1%"@3S%5nF/b&-P91"@3S%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*1^u;tt'^rCBK!'_^qHH5R"1Qm>!_(1%2318aQhNsObg)3ai/aNXW5f=6CiQ'74r)$\3M,"b?h%NE=0I%&-_DfJBMM'sqnHm."[-u^S0:PS8WiuDV!@kpcSV@;dJLG@^TUo*e>Q-Z38+`?C6(Tf9;qf3Wo"LG%l.p]g%r/*s6HX\"*m#AUoMe<V@dq>jm5:cL/qi(&W;3TCUYRt;=`doB]/C^cs*47`;%kT;<me?AIPJrTZXCQTo,'PE]T#K/=aWg<D._'4%&A:<?gZK;';QlEt9Tu,:B0BG=4hg]FgEtCFkg>;!mo-B+_Ln(ddO$1jF_,WlmU&*Ab3&,o\q/8-/"8\E"/A^02KuDZ2sI7kS%BpnO:k3/BepRsAuF-#lH3^7h8*4CFj6PiK<_B@R_MaM::fQrTp*'AO\C$X.A!JB(rpuG=UUnj@3"R4Q9a9D3*,=MQ9a9E.+C[;K"?e9W/Fi2,4D%L<`c[7l7U)LY%]'/D2^_cdR'ne(kK8oKi#8+*j^K9W;C7(?-uP<HrGTP\t[/?2q"/+T&idmdMd&LY[[Vu9J(BM$_hO8XW)CC$_m'c/Tiq/U2HhWFYQNurXD=C-@f8tGLM_dQA&2Fe';$;.EbW9ZNV:j/PDjVW#9_$92j'R/p/<FUi*.DFW&B/<O^H^O/CT/pXBBh6Ae%a<"$>r,D&""="UA/=Je&b5YOgV_c!K23gmR0V94Ligne tronquée
endobj
5 0 obj
<</Type /Encoding /Differences [24 /breve /caron /circumflex /dotaccent /hungarumlaut /ogonek /ring /tilde 39 /quotesingle 96 /grave 128 /bullet /dagger /daggerdbl /ellipsis /emdash /endash /florin /fraction /guilsinglleft /guilsinglright /minus /perthousand /quotedblbase /quotedblleft /quotedblright /quoteleft /quoteright /quotesinglbase /trademark /fi /fl /Lslash /OE /Scaron /Ydieresis /Zcaron /dotlessi /lslash /oe /scaron /zcaron 160 /Euro 164 /currency 166 /brokenbar 168 /dieresis /copyright /ordfeminine 172 /logicalnot /.notdef /registered /macron /degree /plusminus /twosuperior /threesuperior /acute /mu 183 /periodcentered /cedilla /onesuperior /ordmasculine 188 /onequarter /onehalf /threequarters 192 /Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla /Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex /Idieresis /Eth /Ntilde /Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply /Oslash /Ugrave /Uacute /Ucircumflex /Udieresis /Yacute /Thorn /germandbls /agrave /aacute /acircumflex /atilde /adieresis /aring /ae /ccedilla /egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex /idieresis /eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide /oslash /ugrave /uacute /ucircumflex /udieresis /yacute /thorn /ydieresis]>>
endobj
6 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
7 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 6 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
8 0 obj
<<
/AP <<
/N 7 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 46 585.8898 290.6378 607.8898 ] /Subtype /Widget
/T (prenom) /TU (Pr\351nom) /Type /Annot /V ()
>>
endobj
9 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
10 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 9 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
11 0 obj
<<
/AP <<
/N 10 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 304.6378 585.8898 549.2756 607.8898 ] /Subtype /Widget
/T (nom) /TU (Nom) /Type /Annot /V ()
>>
endobj
12 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
13 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 12 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
14 0 obj
<<
/AP <<
/N 13 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 46 535.8898 290.6378 557.8898 ] /Subtype /Widget
/T (email) /TU (Adresse e-mail) /Type /Annot /V ()
>>
endobj
15 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
16 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 15 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
17 0 obj
<<
/AP <<
/N 16 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 304.6378 535.8898 549.2756 557.8898 ] /Subtype /Widget
/T (tel) /TU (T\351l\351phone) /Type /Annot /V ()
>>
endobj
18 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
19 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 18 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
20 0 obj
<<
/AP <<
/N 19 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 46 485.8898 290.6378 507.8898 ] /Subtype /Widget
/T (naissance) /TU (Date de naissance) /Type /Annot /V ()
>>
endobj
21 0 obj
<<
/BBox [ 0 0 14 14 ] /Filter [ /FlateDecode ] /FormType 1 /Length 435 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF] >>
/Subtype /Form /Type /XObject
>>
stream
xœuSINA¼÷+ê¥Ü—p†/ |ü}GöH3-!«ªU©È%r믃×ûâõ„oÎ÷û"¶¹ß¿Ö۱ݜºÖî ¼–ëe\þ.Ú~~¬sáñçx>¾Öæ„ÿxÿª—§£¶$“òêݭʾ~C´jƒÈ IÌ×çbÚ¤Ô²X6•±ŒR¬u-ë85ÁäuDŽ(?3é[¨ŒìD1XîЖŒ[]…˜oKï%H­ª˜í¶Ó\š}b•ìU‹¡ô’Ū`“[$Ï␍ Ò…©Ù6P�’·#[¯¥»§2½"™0ªò
LZ„øjÅMuE¨8xbGGÂU(s×=)ÙåÞ5Iu¡Í²Ó)zTˆzzwæ\ {ô}æd…´$õøfµâ)î‚i“ËIRêá@œ©Â†$›Ñ ßa!vckktÚ§§Ha²>u±YÒ‘‡n4V%È´$õÊÕ
SŸÍ¹B+ý\
°Ýú0# Ÿ¥›±Š‰Ú9M&3Ï+iãEæz/s›‚äLwO¾˜¤†ð˜¤`4çFÜÖŦ1ˆ¯Ÿ«ÿ¹>ðû=ÿZ¸ªendstream
endobj
22 0 obj
<<
/BBox [ 0 0 14 14 ] /Filter [ /FlateDecode ] /FormType 1 /Length 74 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF] >>
/Subtype /Form /Type /XObject
>>
stream
xœ+ä2THW0Tpb,JW0BC*JUHãÒ3515°´PÐ33´43Ò¦f&æf
A -å
z¦`lh B@Å\�ç€endstream
endobj
23 0 obj
<<
/BBox [ 0 0 14 14 ] /Filter [ /FlateDecode ] /FormType 1 /Length 438 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF] >>
/Subtype /Form /Type /XObject
>>
stream
xœuSIn1 ¼Ï+ôBÜÉølÁHœƒs°sÈ÷SÔ3A«!¢¸7}\x½-^O‹úë|¾­��mÎç�õóBÖÛ«¹gXâÞ%êëå ž×&??ëxü¹<_>1|ľ݈ÿ?ÕËÓ¥H’·òjêVe_¿!ZµAd†$æë}ñ¦­»e±Ð.c¥XëZÖq4ÁwäuDŽ(?‚™ô5TFvŽ¢,)´%c©«læd©â½©UU3j;¾àêÐìƒUNA‹¡ô’Ū`“[$Ï␍ Òe7R32P�’É‘­×Rê©L‘LÕy&-²ùÑŠ+z×#²‹ƒ'vÄæHø¡
eîº%%Tî]“Tgl´Y(}G�
C�—qgNÁ•°Gß©0'+ %©wÀ‰ÕЧ¸L±LrHJ=ˆó®°!ÉfôÂ),°‡­­ÑiŸž"…Éúè‚XÒ‘‡«wdZŠzåÑ
SŸÍ¹B+ý,Ø®}˜lŸ¥›±Š‰Ú™&o3ÏëÖÆ%ŠÌõV.æ6É␍˜8ާÂ&©!<&)ÍÙˆëºØ4ñàõ}õß×/<¿ç˜þ¹Zendstream
endobj
24 0 obj
<<
/BBox [ 0 0 14 14 ] /Filter [ /FlateDecode ] /FormType 1 /Length 77 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF] >>
/Subtype /Form /Type /XObject
>>
stream
xœ+ä2THW0TpWг„¢¢t 44¡¢T…4.=KS =SSs3s m`adlªäÔY®` g
Æ†Æ ÔQÌ#$endstream
endobj
25 0 obj
<<
/BBox [ 0 0 14 14 ] /Filter [ /FlateDecode ] /FormType 1 /Length 435 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF] >>
/Subtype /Form /Type /XObject
>>
stream
xœuSIn1 ¼Ï+ôBÜÉølÁHœƒs°sÈ÷S”�™Œ@jˆ(îEöÇ�×Ûâõ„oÎçÛÚ8ls?¬Ÿ7òÞ^µ(<Ãï.Q_/ãòwmòó±Î…ÇŸÛóíc‘ÀGìÛ‹øÿS½<ÝŠ$y+¯¦nUöõ¢UDfHb¾ÞoÚº[ í2–Qе eGìñ@^Gäˆò#˜I…ÊÈÎ�(K
mÉXAê*[�9Yªx/AiUÀŒÚŽ/ruhöÁ*yøb(½ƒ�d±*2 “[Ï␍ Òe7J32¤BJ&Gµ^K©§3½"™0ªò
LZdóÕŠ+z×ÙÅÁ;bs$üÐ…2wÝ‹*÷®)ª36hJßÑ£BÄÐãeÜ™Óp%ìÁ;æd…´$õ8±Zñ4wÁË$'I©‡qÞ6I²\8…Öádkk0íÃ)J˜ª�.ˆ%u(�X•x CI(ú•«¦>›s*ý,²}ñ0#Ø>K7cµ3MÞfž3Ö­�G•ë½]Ìm’;0qÜ=ùb’Âc’‚Ñœ�øZb^ßWÿ}ýÂï÷üiK¸Áendstream
endobj
26 0 obj
<<
/BBox [ 0 0 14 14 ] /Filter [ /FlateDecode ] /FormType 1 /Length 74 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF] >>
/Subtype /Form /Type /XObject
>>
stream
xœ+ä2THW0Tpb,JW0BC*JUHãÒ3µ40µ°PÐ335731ÒFƦ
A -å
z¦`lh B@Å\�è…endstream
endobj
27 0 obj
<<
/AP <<
/D <<
/Off 24 0 R /Yes 23 0 R
>> /N <<
/Off 22 0 R /Yes 21 0 R
>> /R <<
/Off 26 0 R /Yes 25 0 R
>>
>> /AS /Off /BS <<
/S /S /W 1
>> /F 4 /FT /Btn /Ff 2
/H /N /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ] /CA (4)
>> /P 35 0 R /Rect [ 46 425.8898 60 439.8898 ] /Subtype /Widget /T (age_15_ou_plus)
/TU (J'ai 15 ans ou plus) /Type /Annot /V /Off
>>
endobj
28 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
29 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 28 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
30 0 obj
<<
/AP <<
/N 29 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 46 351.8898 290.6378 373.8898 ] /Subtype /Widget
/T (parent_nom) /TU (Responsable l\351gal) /Type /Annot /V ()
>>
endobj
31 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
32 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 31 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
33 0 obj
<<
/AP <<
/N 32 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 35 0 R /Rect [ 304.6378 351.8898 549.2756 373.8898 ] /Subtype /Widget
/T (parent_email) /TU (E-mail du responsable l\351gal) /Type /Annot /V ()
>>
endobj
34 0 obj
<<
/AP <<
/D <<
/Off 24 0 R /Yes 23 0 R
>> /N <<
/Off 22 0 R /Yes 21 0 R
>> /R <<
/Off 26 0 R /Yes 25 0 R
>>
>> /AS /Off /BS <<
/S /S /W 1
>> /F 4 /FT /Btn /Ff 2
/H /N /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ] /CA (4)
>> /P 35 0 R /Rect [ 46 319.8898 60 333.8898 ] /Subtype /Widget /T (accord_parental)
/TU (Accord parental) /Type /Annot /V /Off
>>
endobj
35 0 obj
<<
/Annots [ 8 0 R 11 0 R 14 0 R 17 0 R 20 0 R 27 0 R 30 0 R 33 0 R 34 0 R ] /Contents 57 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 56 0 R /Resources <<
/Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ] /XObject <<
/FormXob.a0ead3c46bdf4dde94efec4094db8672 3 0 R
>>
>> /Rotate 0
/Trans <<
>> /Type /Page
>>
endobj
36 0 obj
<<
/AP <<
/D <<
/Off 24 0 R /Yes 23 0 R
>> /N <<
/Off 22 0 R /Yes 21 0 R
>> /R <<
/Off 26 0 R /Yes 25 0 R
>>
>> /AS /Off /BS <<
/S /S /W 1
>> /F 4 /FT /Btn /Ff 2
/H /N /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ] /CA (4)
>> /P 49 0 R /Rect [ 46 705.8898 60 719.8898 ] /Subtype /Widget /T (accord_participation)
/TU (Accord de participation) /Type /Annot /V /Off
>>
endobj
37 0 obj
<<
/AP <<
/D <<
/Off 24 0 R /Yes 23 0 R
>> /N <<
/Off 22 0 R /Yes 21 0 R
>> /R <<
/Off 26 0 R /Yes 25 0 R
>>
>> /AS /Off /BS <<
/S /S /W 1
>> /F 4 /FT /Btn /Ff 2
/H /N /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ] /CA (4)
>> /P 49 0 R /Rect [ 46 658.8898 60 672.8898 ] /Subtype /Widget /T (confidentialite)
/TU (Confidentialit\351 de la b\352ta) /Type /Annot /V /Off
>>
endobj
38 0 obj
<<
/AP <<
/D <<
/Off 24 0 R /Yes 23 0 R
>> /N <<
/Off 22 0 R /Yes 21 0 R
>> /R <<
/Off 26 0 R /Yes 25 0 R
>>
>> /AS /Off /BS <<
/S /S /W 1
>> /F 4 /FT /Btn /Ff 2
/H /N /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ] /CA (4)
>> /P 49 0 R /Rect [ 46 611.8898 60 625.8898 ] /Subtype /Widget /T (rgpd)
/TU (Consentement RGPD minimal) /Type /Annot /V /Off
>>
endobj
39 0 obj
<<
/AP <<
/D <<
/Off 24 0 R /Yes 23 0 R
>> /N <<
/Off 22 0 R /Yes 21 0 R
>> /R <<
/Off 26 0 R /Yes 25 0 R
>>
>> /AS /Off /BS <<
/S /S /W 1
>> /F 4 /FT /Btn /Ff 2
/H /N /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ] /CA (4)
>> /P 49 0 R /Rect [ 46 551.8898 60 565.8898 ] /Subtype /Widget /T (suivi_reseaux)
/TU (Facultatif : r\351seaux sociaux) /Type /Annot /V /Off
>>
endobj
40 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
41 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 40 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
42 0 obj
<<
/AP <<
/N 41 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 49 0 R /Rect [ 46 467.8898 290.6378 489.8898 ] /Subtype /Widget
/T (lieu) /TU (Lieu) /Type /Annot /V ()
>>
endobj
43 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
44 0 obj
<<
/BBox [ 0 0 244.6378 22 ] /Filter [ /FlateDecode ] /FormType 1 /Length 120 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 43 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ;
ADó:E�`ìîížOê"m ž@Í×@�ïLª<ŠJŠG)µ³Ý!š{ÊS)-¬D4‰J3nWÜ�ÂCZeÊÚ²ôŽìE2O ”oH
Ž˜O†vç÷ëL<aì¸ü.µŽå�~fZpÄa�ñªÁ!=endstream
endobj
45 0 obj
<<
/AP <<
/N 44 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 49 0 R /Rect [ 304.6378 467.8898 549.2756 489.8898 ] /Subtype /Widget
/T (date_signature) /TU (Date) /Type /Annot /V ()
>>
endobj
46 0 obj
<< /BaseFont /Helvetica /Subtype /Type1 /Name /Helv /Type /Font /Encoding 5 0 R >>
endobj
47 0 obj
<<
/BBox [ 0 0 503.2756 34 ] /Filter [ /FlateDecode ] /FormType 1 /Length 119 /Matrix [ 1 0 0 1 0 0 ] /Resources << /ProcSet [/PDF /Text] /Font <</Helv 46 0 R>> >>
/Subtype /Form /Type /XObject
>>
stream
xœeŽ1Â0CwŸÂ'ÿ'qÚ¬T¨SªJœØ�(Ÿd®,ËËÓ“�Þ²?a4ÊRˆƒTMrÝÅ”¹ßñ@P–Õ‘¡x-ÖV%V¸Îp~aAì•Ń!uçíÇó2oDFæZ¤uò†W;Ó͸â²Lø—v!endstream
endobj
48 0 obj
<<
/AP <<
/N 47 0 R
>> /BS <<
/S /S /W 1
>> /DA (/Helv 11 Tf .176471 .176471 .176471 rg) /DV () /F 4 /FT /Tx
/Ff 0 /MK <<
/BC [ .545098 .619608 .564706 ] /BG [ 1 1 1 ]
>> /MaxLen 100 /P 49 0 R /Rect [ 46 405.8898 549.2756 439.8898 ] /Subtype /Widget
/T (signature) /TU (Signature) /Type /Annot /V ()
>>
endobj
49 0 obj
<<
/Annots [ 36 0 R 37 0 R 38 0 R 39 0 R 42 0 R 45 0 R 48 0 R ] /Contents 58 0 R /MediaBox [ 0 0 595.2756 841.8898 ] /Parent 56 0 R /Resources <<
/Font 1 0 R /ProcSet [ /PDF /Text /ImageB /ImageC /ImageI ]
>> /Rotate 0
/Trans <<
>> /Type /Page
>>
endobj
50 0 obj
<<
/Filter [ /FlateDecode ] /Length 688
>>
stream
xœeÕËnÚ@Æñ=Oáe«.ÀsnDBH¹JYô¢¦/@Ì�"c²ÈÛw>(µHÉùƒ=ÉOxqæ·�w�ýþÜÌŒÇî)Ÿ›Ý¾ßŽùt|»Ü<ç—}?kS³ÝwçË»éwwØ ³y9üô~:çÃc¿;ÎV«fþ³\<�Ç÷æÓõôú²Û¼žòçÙüû¸Íã¾ùïÂÓÛ0¼æCîÏÍb¶^7Û¼+øëfø¶9äf^ßý÷Ú¯÷!7izß’Õ·ù4lº<nú—<[-ëfëYî·ÿ\kÓ’gžwÝïÍx¹wQ^ëÒíÔ÷×è4õM …ŸO÷(û
mSßN÷;{ú<Ø ½dOg¯xv‰¾®þïMÕ·UßU}_õÃßn+ÛV�ª–ªµj«Ú«Žª—U_U]ùÛÊßVþ¶ò·•¿­ü‰þ45ýe”¦?á;Lô—Qšþ2JÓ_FiúË(M³Kô'|ç‰þ„g”èOxv‰þ2JÓ_FiúË(M¥é/c¶ú~¡_àú~¡_àú~¡_àú~¡_àú~¡_àú~¡_àú~¡_àú~¡_àWú~¥_áWú~¥_áWú~¥_áWú~¥_áWú~¥_áWú~¥_áWú~¥_áWú~¥_á7ú␍~£ßà7ú␍~£ßà7ú␍~£ßà7ú␍~£ßà7ú␍~£ßà7ú␍~£ßà7ú␍~£ßà7ú␍~£ßàwú~§ßáwú~§ßáwú~§ßáwú~§ßáwú~§ßáwú~§ßáwú~§ßáwú~§ßáúþ ?àúþ ?àúþ ?àúþ ?àúþ ?àúþ ?àúþ ?àúþ ÿ²!.›»‹ícýtoãX6Ó´ý¦Åƒ•³ïóÇ‚ŽNáçÍ­š;endstream
endobj
51 0 obj
<<
/Filter [ /FlateDecode ] /Length 7257 /Length1 11296
>>
stream
xœ•z @[Ç™ÿÌ$@\º¹yB a›[—sØ€␍cã„‘’�Û$ŽoÿÝ$>‚qÒÄn“:ŽÓz§›&n’Ív“ü§MºéÆÉ¶Ý]oºIsz»Ý&k'©[žö›yO€�óÿïJ¼÷¾÷ÞÌ7¿ïœo!ŒŠC{�qí]Åe=ÓŸ§Ã“ÂÑ×?â
ÈuòAÇáÝêÝ9¸Û¯Þ…ÉE(+wÈí(Y›o@ˆ[ímCð öZÔM¸ß÷¹C#c;>HM}îÏBÿ³^¿ëØò7"”CÛ¿;âÚ@Ï 2àžó¹FÜ]ñÏšàÞŽPÌ+h,ü:*G¨Ñ÷(Š8ðq␍ãßKzàI«pÅ›P9ŽAó>0üÖù÷ËW7µ£—÷g"y—¿ˆÖKÞÅ-B'è;ü9͸SaÖ!Iq\„<# Ÿ(YŠdÐ.ýo>qHüP"JBÉH�”H…ÔHƒ´H‡RP*JCé(e¢,”␍(ô(P.ÊCFdBùhZŒ–€
Q*F%¨•!3² +²�f*P%ªBÕÈŽj�Õ"'ªCõh)j@�¨ 5£eh9jA­¨␍´¼µ£Ô‰V¡.´u£5h-êAëÐz´mD½hÚŒú� mAýh¹Ñ èpˆI@ -¿'ÿZ�!dVèyf…a␍~�ÿÉÌ ù‡™’fb…vTþ’D“·@âL�©Ême:�Ád”Êdª£Õb+Ój4z­Ö\V®“b½Ñ˜#½§ÁÈipT'/I®>vèÊÞ3´"PZRÏ_ÄpßôfâØ\Zº¹S‹5�3Ï?02<uÈ“×êZ›¶§¶nÜDíÓ�cÑÓ¸Ÿ¢Sæé0ê“Æ´4cŽM7¦¦#Ø“7�R‚¾‘
p ˜Ì”Á*•šÊl£!GªÖþ.XÚ7ttÊ;<]�áµw��yóÈ‘™%ÓÛ<'¦¶]­XZ|,³rSÞ°&†r³ääÅ•uÁúƒß$(ð_( { b’½¦ßªU¬Ï±*,f½Fü~¿Áà7ˆÚÄuü.§Oò‡ðÿm¼ŸÜ˜S£¼–dÕÚ¯Û¯ öøïü*½ê6¾¸PwÞÎïÈ_î™Ïô|îb85·#•¨€VLÑ2•D/1æ\œ‡ôõ—RϦ¾TWÉ?Yõã­Øº5aå-XÉšŽŽ™óƒ_$KùgðÊEóÇ¢˜jçö1°ìøÐæ’}GùB® ì8ç# íø°>õ␍fd~r';ºÂ_£Èã 3RA 騷‚ª¥þÚÚ,eZšR•šJç—_O¥~›
}ºñE¼”¼$ÄžJaP@7ÅTÍjÈKüM,¥³¡ �ËÒ!� s¹Á*f;4vÊe²rs¹ì‘Âo}Û1õ½‚ª‚Oà8pÂqú¯
«
?)´âøä\ÅGågàcû¸üÉ'ñ¹÷>Æ,Ö„ÿ‰“h ó ¬Ñju2*u–D—¥QK␍BFS9Õ‘Íj)’˜Š¢@oåV\Y?˜j-Þi_«N· Æg^úî^ÇÁ"›vS]óuš%7ÇXRgLw·I4!icU†»Ñ’š¯ÓÄÊb3sí¦ÕÛF't#饶F{šI§ÝòqÀ�´á›ä—ä1ÈÊ �Os¨_¨„¨TlÆ�×xö…‰=¤h¿kokÛѺBëÄËjyO^Y©ÑTZŠß¶·¶ÂÓ*¸o++Õƒ§Ýí­þur𣣼ºµu¢�ŸŸÒmUÕm`‡áäEr¬°4EGÐélà62p&©�yS¹�v@…XM}Êd4I¥x¢¬aýßVhÊÓœ;×¶õîÙ¶¿»¥xpÅ!»¹€i`EËkʘŠf²­¾¸­ç'ËÝZçDK·¯»aP[ß°¬ooæ¾Ã¾²þeelb;râE4Åü†yÍ”è/ì]kx+¶�ŸÁÜ„lɶr␍©1¶NúŸ|Ò/Îx¿®áÐÇ×ö7ÔÓ¶…ÐV+´EÉR™ôf²j±vÒã?|¿¾aß¿r°¡‰ãZðŸÈë0_!;å žÕÒêL‘l«'Œ:j␍CŽÉ$“þD®Ê_·»)K—;ªŒV$%*¢UÁÅŠ„äe»z©â3uÕÕ©Ø¢Œ××ëÒ²5•÷hS’5šd¹áž
­2!3^½1W'WVŽª´‰T;ä"„Íp~pPlt^¹â|ûmbÛþöÛvsKxzfFh«3”‹¯–�-ÎVÃ$BžÿIBÄ¥Jm}8?‡»¨^±&ÚŠŸã_À]•Xâ›ò�HÕÞ2ňÓÂá?€>uäí/S™%ÊϜזôþåqÕà;6ð�X¨P´˜y’g'&pV\á?~ü½cÇ}ÞáÎŽ¯ügS\¾Ì¿÷óº³×Î<>6~–ÉCe6ŸD„ô…Å�#“™�cƒ3Nš|*ó{†ÌÔ,²*1¶·ºW­Ï‚>eÐç3è“}ô‚álbàÈL¶ˆ¹¤j³ÆÿÀ¸$ï×ÅK:ª,ëÒ͆`ËšÑÁS'â^SV¾þÕ%Í…ÖÆ*Kf}Û`ÛðÆŸ+µ “3|‡!?AT¨¬z‘›FmfŒi`@ò0 ¡j‡·Z ر¸¸ø]R]kïž␍íÙ¥w9{›e™9ÜÔi¤Ï^ÈäM(eq›ÛºMuYC+ªËí¹)y)ûU:ªS˜ë‰äRÓ¼¨7XÙTBV€_ä陆$ÿ�ƒÿ,o‘öF¼*G—‘;>Îÿ'%Ç+®Ç5ddeãA¥J‘—ÉTUᣚTþ”<.™Éf ‰ßÙ²˜Õf³  ‰B¯‰ž•Ç5�eØÔk­Îu]Ë<¦<Êÿ}öà€o2®¦"§°h•£®¾Àˆ£íøå¬Í×Oþb𠼓 V|¢\e– ö�g=§ ,|ù}K
68tþèÀ@skŸ|ïæ†~Ì]WÝãê?Pí:êòÔ73¼à]ø<ð„YÈlPQ=ëÁ$`‘g?OÌæ_Ç›„ãä{k¦ <µ•ÕNç`Vä¨ý¢Ä, ©L gÉ\J%³$þÁÕ}Ëì6ÇÝ?»Ûa«iúÏֵޮëŠ:Ó·å»ýq[ºª×%%¬­êôx:«Ö$&õTwaeCuÅòåö¥üåÆ*G}½£Šé :8'è3ß‘ÊÅlª¥™�éûN: çönnîãÿí6%!Vñ@¬&ÍU�ä–¨þð ¼|K$†‰�/X_Õ\_ɼÌ!ô¯ó‡Èaæ‘ùyÄŽ‚ø×ÄDm�§É£fÍÓDÓDŒÍ?×Ñ�[ùW8îÙúÍ�™;êGåéñlìnô×$*Ô4EÃA²y~ŽO«±ýÏpymŒñ'qŒhkMÝyÖh-5 ÿ®å8þÜÚqmG}0>=C>Z¿#³±‰Ž‘þ
¿C΂¶¡ŠÏ3X’ÛA¢„Dê"5Îh0ÚlÆUU•=©¶ìP{Ï„Ñj3*rÓÒrS?È©È_T•ki¨¶f/mßÖ^°¼Ø´(ŒRUÊÔT¥ŠÉ³9¼Jò"¹V96k®"7G¦m�Z¨»ÀÚÉ¢ÛÄr=âoxf]prý†ÉgÇߟ>õµC�ŽÔõûû׿¼üôG{–¥õÕnÞp §;sbÝúÝã=ßZwðo><ùð«•Kœàžð¯Nûn*ª°n©snpÕÕ¯g¸X}Ér1ø‡ù¶Ê²paź°H• ðX␍q&�d…�F©Ö"J€pJáš_þjòÞÝ÷ñëOz6º7>ü@qƒ3g`„œ^×µ/;uÏE2p³¦Ñnçߺ—fËwV6.„ü°Ÿ<9›¨Š ²˜Õ­=¤ø®{/]ºwõýù–œÑ¥¾Ó§üKGs,ù÷Ëß8~ìç�ÙµOLìx¢¶<»±�ÉNqÓüëU„©¾)pMh@ØÈù·N_ù§G/ÕŸÙýðÔ=çqשçÉéç¦wœœ¹úÃÄÖ,gѹ䖕1ÝºŠ˜·€À°êD$‡é ò’Ð ²§þ è°‹ß�ùGHo­�ÿÂ.Ê}ì“þ�r[Í*ùý¯¾zÿªc&«>Tç?uj´.�^›wDþæ±#o¬hήpœŸ8g6üðÿš— úô1»G0ÐÅ.-¸õç“Aý÷K\:3€‹gÛ£ Ð^"Tô>§“œžÞņgЇð.ê
+˜X©¥±-�ΠÄÙ³¿À·ŽìŠŒ9íTâ˜f[9íR5[<™ 0¶7Vÿ˶ßåç_ë|[7 Þ2æ~Ê—Ôñæ,žÅ-l•Jµ_À½üãÎcöZÒ má°d?è,—Ö9*Ë:•¶¬\%P‰‘M„t2fäîº>i‘>³0ö¸T-=¦¬çŠ¢×:WA‰™N,Õ¤'cU°"› Æìl>J£Á7kM¹3çȲ\Ž—§h ÊÎev…ùã Œ›*ؕ־L$èŠ? ƒiÎÔäZS±&1YYSÈU¤ð×ⵤ}QQÙÌ;édÍÌ�ò‹ÊHY*'¬YéZí
yêRmĸ¹Ê^¬–ö»ôθtéèè£�Ž}4îõ©ã—/Ÿz½æ‰í�ŸßþĬ¿¯ÝÅE, fsw`wÁùÊ�S§÷îß·o_ÿÎíäôøhhOñçW÷tw‹X>,‰(␍°è�³`dfsÞ<<äþÄ}Ku4)Nòß� Š~í…µáÁ⨸V.-[ÓEpÁlK£(jÀ§jßÙv°§­ ÊTÙhUh␍ ·múÄí.9½esK_‚²£=´␍–_)
¼šÿdySc#[Ó}Mâ`=ZrkÝY½ uË2çwîN¿}é¶«§e"ý¶5ÞÞ˜eu m+·59®ï„X�9
)ø/Ö ä Vüå?:ß%§í3�A�GÛl¼[…¼Å™ûhŰ¿ãÿrÀÙ¹ßóÈ}x7¿Ï?9éÇ÷ð{ï…~Ù�+¼Ð/žÊi’˜™Ï›%RÜ´&ëÇõ’:’žªÿq–¼�4Ï\6›IÕÌ } ¾!¹�|é*§½Ì4TÊt‘îBœÐˆ¡ä�»ejMìΤ`òžØ|iй]QgX$ß�=S�•]ä$g.ææ’Øúº™¯àº|懫ò“h�næsƒÑ$è![Ì?™Ôâ´6™Ì:­NL šHN�ÊFV>«×?Õv*CV“þHÛS÷ÜÊG3c*¥Y|iŽ¡ô«÷™ßûª8ÏTÀ¿¿h±±Pà+)þ
V␍™6˜` � ×8‹³k<)×)3µ6žÉ(}/i)öòO¤èŠñ~ziãk;’<Rií"Ô8REÒù␍Óž$ð;ò‹3p(1ƒ?Ž'€ä�$fØí…ú<?œœ¨e¿(–¿`]T ë"È»Ñ6g@m®0ãÚœÎÇx¸–ü¶Ö>“ÎÆO�¶uÂJeVRœŸAOº„‚w%ð |t°Þ72—iêWxàðaçÃvò‘½vF_+è¢ ×ã·Éê*M‚,æÈBuweTT¦írúâ â¡M.̺W±4‹®“ á—ðÕð␍:6­¼ðU¾Y^�+¿&â@7ÙþÛ;:¬ ÑÍ Ù|µÿrDʼëö�GlX°í·pÇ‘òëŸ^r&"�À¢@¬Î~Œ]ûð´#{Èî=>åV��ä'¶á+ü¥’Š)¯gø…BŒ�O¿Ä7dÀh©QÜŸ0µ5ÝõÊuOM¹�Õ[ÌÛZ}¾V�ÅR‡O^™Þ‘µ!ôÝÐúÌ‚Œ7`�0“�CT4ÍÏaZâ�:>lÊÆŽéáÎÀèc�€|Úã�ª(Áv¾hÛ‰YP‚΢ñçૺ¹õð‚UÓ�·áâî°ULí§]`#5˨àÂ^Œ†NAt›àG__ÏŠbcn�÷…ðS˛֪º�e �–Ù0␍åÝ’1­Rq-Â,ª–Jæ-ØóZ'9KÚÆªuþ4OÃÐqjÜ©‘ŽÑÑŽöÑÑkN{faéö-␍Öº)fä_ÜõÎ >mïŠu”ô© l—¸Ÿq82\Uƒ޵ímýäÿ‹Ëÿ§¯¯kvß=M.BN•Ï­SdÒõIj«ÃAÖ§ÓÓò�ñX$|3œ†~ÄÚ+nis!�V{­[IÊ*#=g>jwU×[gë>B^û¦:ð.�Q>½òÝääw:ŸRÄ6“×øVµòéw“3’ÿñ‚25Â�‰Ä¶Â0/͈ë™(ª'Á²…U "¢¦ñÊ<Îf#gÆ«Z—u9VOw8‚[Z†Š~üùaO}ÕéîøóÍÎá‘ίÞoµ×Õµ ¼‰l«ví"¬Þ¸¼}½ãîá‘ÝŽ^ü\`Õ}í½ÿ>X5Šn‰í8êUQ9sû\sqýЯ¦OnóNñ…�,¨‡¦Ox¶­#šÆ³ž¬`ùAG3—Âb›ÛÑFø…��èñBôиN¿Åïl›:áñž¨,)
Q^½˜khÜóÝ3*‹,vd{ìÃÌ#ù¿†ÔÉæ·¸¦¤ò„—ºâ%‘›¨wÜ�/ì(fãEª9êØÔUœ—»¤¼/Y3¬¬Õ´8hû
X?>ís@’œÈ¾ŽXRÌU ÜlfÓ&sÃg‹sI_ó³Y¿fImuwwõPì¶Œ¶‚üŒÜuJåûÊ�™µKr¹\EJ�ÙÙNLj ßÀãdiÄìG#™íó)XÆÒH±ºmíÖ­ŽË—+K-ù‹äWâÄŠ½{+øëÖ½=[� ì¦ÃQ›Ó2␍ú3}3B‹ËV€Í=[ïrô”Ž®úükï}÷{¿ú¢sú%ÁØ_A¿x±.ˆ”Ï<^JÆÉNÕŸÕUV—âgù�J%>Ë·ÙÅZB 6Éf:™­&ÌsåDŽI¬¿µTéªî•é4²5ªú:ewL�lcUŸrPºé¥¼␍˜egà␍­-üÙŒlüm~c[ îÍÌäoíEJßÿ·†x¨y¿Vs yT%­�V–Ðh÷7�ª¥52ÕóÙiY/~'-3-ó;/f¥ed?ÿ�Ì,}šàM�•ÿ¹,h²2Ý)¨î˜2!m`CógI]g[»—Ý=pt=²Á±ëZMufAÑxoƒ�ã?¯î÷wý‘wìœf¼Káô2ðN�̛݇_ZÐ-³ÿÿº©(ë”zþר $ÿ™R�‹‹²—èÿ%Q‘VÁˆ¥ˆ·<܇�ä´Î…U!+˜­ó¼X=»‡%n6hÄx¡é¥<¡¨¼¨Á–oÈÊÉ2™ ÍEF sÙàÅ×öB£þžE¶fU�®€3Ü�›_S•Ÿ{·�+Ð9ÕͶE÷èiå…Q ¼Ö‰ïмÑm¾àpì’tÜŠ␍ƒ÷FàÀªÈª�…*ìµ±l'³Š‰�º¨%>¾¸¼¸Ñ¶('Ë�e,¶ZŠ�@òm�ÅåØA§v.DW§šEGñ-C׉ïEJБ°Í#l€&Ôagt}Iþî*c4%Lws™ÆëŠÒ†ÊÜ zÎCÂÿˆÐû‰uÊÍIö1rɧ”íÕ C/½~óJQxc8VÚ+9·1�£„ôþ'/}Þ'I{ÅÿÀÏ}<d)ZC*P!ŽBÝdRšô¡v|èï Ï0�Ò� uKœÈA–¡òÒ’¯Ñ
ô êÆ.Ô
G!Y |ŽÀ}j!ä£|qqøÄ�*ñI$'Y¨Œ´"'©C$YH *Æo!5G­ŒŽûZ‘�Œ/+ÚD²QnTṴ́G>¨) Éûp¥›�›¼ ÷ŸÁXpÔ£X²Þi�Oò
à¼ïÃð>÷Ipý¼£Ø%(�¼Š6�ûP¶ä¯GAÙÄŽ’‰a?ð)F)p-!êØ02àZ¨?©~&QIaWA/��ÑÑ–BMð_á›$—Ñ’7 m޵b?h‡—£ü¯¨¿ˆâÈVx&EIŒ¿h/j‚VŠ·£rœ…ôJºý=‡²Ît½ŒþˆÕ¸�á³ðý)¾ÁJò ùgò)á%ZÉzI@rH2-9'yVòÉQ9Q›¢ŽGý4êÓh¾µ-úpôùèËÑW£¿–I'¥§¥oI¿–¥È,²Ù„ì¨ì´ìG²+²c¸˜–˜@Ìñ˜—b~[ÛÛ{wìÅØ�ãbâÊâ–Å­‰óÆŠ›Ž;÷FÜrµÜ.”�¿$¿*¿¯Ž·Å7Äã�Ç?ÿ›”�’Ð’àM8œp&á7‰1‰¶Ä¾Ä3‰¿HR2Oô º"e³|ä÷!ÎYßäð¡Y­Aw‹4FÑè²H$Eÿ,Ò”†u"…¢±C¤£Qîi)<ŸiØõc‘ŽA*ðG�ŽE‰`3�–£LòÓÙ_­TIV‰túCô°H'¢té”@ÃI%3‰4FiÒŽ¢¿h™d)␍s+zQ¤ pý…HK�½/ÒQ(—‰t4ÈÕ ÒRxîiøØ‘ŽAF’*Ò±WÝ"-GUdŸHÇ£1rU¤ðUÉ‘ND6éz�àFiX¤1²H/ ¥È�h'
‚­è/VÆ‡ÊØ/e*Q!£Ê€æÐräƒÚÒƒ\påÐjè@n š ÿ8{„gEð¤yáËÍãbwn¸ºá:çº^êì z¶�qe%¥•…e%e¥Ür߀ÇåãVï ¸¹&ÿ¸o ¸³ˆ«óz9Ö0ÄÝ!wpÂ=Ý‹—ñDƒ.o.+K�°çh¥?8â‚k) UÂ¾Õ ÄjÜÔRæa@]hº
ØlAè=¬�J‹JJJªéŸª—y¼^׎ÂUî­ã^WðNã®ar…€¡ŸignH´Æ yü>Ž1¼Sß[�p@Sm¹àž.ö[¢jžù�}3Ätÿ?µ eà<!ÎÅ�]îWp˜órcCî;êý™£;tF0aÐ^ã
ŽƒÔæbî0LµÂå␍y¸WÐ3 ÷ÔCÆ€yU¡bøzæ␍<&;x›Dýp?]ÇÆ¡ªâb1Eüýþ‘…œ·³oÑÿb„b¦ÿódŸhåbf�9ñ
¡ÿ<ñ"˜¶oß^tG\Åî�g«£xDPEa@TÅjÆ0$jÙÇ‚±‹} €»XE\$w~xî¨c,¤8Q
“ƒ+€‚ƒýÌ©|¬•‡q¦­|ðlLt[ Ú;9]¤_ÿRuÛí,ì×1ÒÖ[N7ãægãQ~>6Ò ôŸïÀ49¦|Ÿ˜(¶°Ïk37z�IéaãÞÊÁÄzúIÄHT��³PºÐÿS¾�¨-¡ÍN¦Õ9wàXº‰Xb¤ïŸÕæ­xC4WAø5ù}c\—pl»+è¦ñúÇÜýcîÄäü#îИ§Ÿsù8�oÌô¹Æ ƒ¸¼ó—¾ëŸÍž^×ö"n�œsm␍ºÝܘŸó ¸}cžÁ�Bx¯nâaØ·e'û•¨Ð=èðŒE˜Bœ;uÉ!O ’f‡ Ý:^`Á“�œàÇœ?H…ï§0E¾¡¢…Ñ7gä!Ñ•ç¢LpÇx7? òh‰Å èa^Ò¹e¾ëºÙ|SçVvîaçuì<ÌÎ; “WТ›«+àZ ¸žn]7\ÀÁ»zf9Á'ÝÐxŒY5Àì8Ç$³!ª÷€2Ý;Æ8`Ì3â™tˆ5 û„/ÑßÙ.üü7ÍÆÄendstream
endobj
52 0 obj
<<
/Ascent 980 /CapHeight 668 /Descent -330 /Flags 4 /FontBBox [ -164 -247 1629 938 ] /FontFile2 51 0 R
/FontName /AAAAAA+false /ItalicAngle 0 /MissingWidth 579 /StemV 87 /Type /FontDescriptor
>>
endobj
53 0 obj
<<
/BaseFont /AAAAAA+false /FirstChar 0 /FontDescriptor 52 0 R /LastChar 127 /Name /F2+0 /Subtype /TrueType
/ToUnicode 50 0 R /Type /Font /Widths [ 579 568 260 634 568 608 608 680 680 568
579 579 579 579 579 579 579 579 579 579
579 579 579 579 579 579 579 579 579 579
579 579 287 282 408 832 584 741 760 231
353 353 590 653 260 547 260 303 623 405
542 587 577 526 560 462 629 560 260 260
565 628 565 543 1061 680 656 674 737 608
582 704 745 284 322 639 533 961 746 767
626 783 649 584 515 706 651 939 666 572
576 367 303 367 514 511 319 634 634 536
634 568 388 634 645 262 243 548 262 970
627 599 634 634 329 477 442 615 518 822
641 620 496 375 286 375 595 579 ]
>>
endobj
54 0 obj
<<
/AcroForm 59 0 R /PageMode /UseNone /Pages 56 0 R /Type /Catalog
>>
endobj
55 0 obj
<<
/Author (JobRunner) /CreationDate (D:20261029103017+01'00') /Creator (anonymous) /Keywords () /ModDate (D:20261029103017+01'00') /Producer (ReportLab PDF Library - \(opensource\))
/Subject (Participation \340 la b\352ta de test) /Title (Formulaire testeur - JobRunner b\352ta) /Trapped /False
>>
endobj
56 0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 0 R 34 0 R 36 0 R
37 0 R 38 0 R 39 0 R 42 0 R 45 0 R 48 0 R ]
>>
endobj
xref
0 60
0000000000 65535 f
0000000061 00000 n
0000000105 00000 n
0000000212 00000 n
0000066162 00000 n
0000071860 00000 n
0000073182 00000 n
0000073280 00000 n
0000073631 00000 n
0000073951 00000 n
0000074049 00000 n
0000074401 00000 n
0000074720 00000 n
0000074819 00000 n
0000075172 00000 n
0000075498 00000 n
0000075597 00000 n
0000075950 00000 n
0000076281 00000 n
0000076380 00000 n
0000076733 00000 n
0000077066 00000 n
0000077699 00000 n
0000077970 00000 n
0000078606 00000 n
0000078880 00000 n
0000079513 00000 n
0000079784 00000 n
0000080169 00000 n
0000080268 00000 n
0000080621 00000 n
0000080958 00000 n
0000081057 00000 n
0000081410 00000 n
0000081765 00000 n
0000082147 00000 n
0000082490 00000 n
0000082885 00000 n
0000083284 00000 n
0000083665 00000 n
0000084061 00000 n
0000084160 00000 n
0000084513 00000 n
0000084828 00000 n
0000084927 00000 n
0000085280 00000 n
0000085611 00000 n
0000085710 00000 n
0000086062 00000 n
0000086387 00000 n
0000086654 00000 n
0000087418 00000 n
0000094767 00000 n
0000094982 00000 n
0000095703 00000 n
0000095790 00000 n
0000096108 00000 n
0000096176 00000 n
0000097790 00000 n
0000099163 00000 n
trailer
<<
/ID
[<5fa3407fd6b71d07a61a94cb83ea98cc><5fa3407fd6b71d07a61a94cb83ea98cc>]
% ReportLab generated PDF document -- digest (opensource)
/Info 55 0 R
/Root 54 0 R
/Size 60
>>
startxref
99402
%%EOF
+49
Voir le fichier
@@ -0,0 +1,49 @@
import io, os, sys, tempfile, unittest
from contextlib import redirect_stdout
from pathlib import Path
sys.path.insert(0, str(Path(__file__).resolve().parent.parent))
os.environ["BETA_DATA"] = str(Path(tempfile.mkdtemp()) / "data")
import db, codes, server # noqa: E402
ESC = "\x1b[2J\x1b]0;pwn\x07"
def sortie(*args):
b = io.StringIO()
with redirect_stdout(b):
codes.main(list(args))
return b.getvalue()
class T(unittest.TestCase):
def setUp(self):
self.c = db.connect()
def test_propre(self):
self.assertEqual(codes.propre("a\x1bb\nc\x07"), "a b c ")
self.assertEqual(codes.propre(None), "")
def test_retours(self):
self.c.execute("INSERT INTO feedback(ts,text,page,viewport,kind) VALUES(1,?,?,?,?)", (ESC + "x", ESC, ESC, ESC)); self.c.commit()
self.assertNotIn("\x1b", sortie("retours"))
def test_testeurs(self):
self.c.execute("INSERT INTO testers(ts,nom,prenom,email,tel,mineur,parent_nom) VALUES(1,?,?,?,?,1,?)", (ESC,) * 4 + (ESC,)); self.c.commit()
self.assertNotIn("\x1b", sortie("testeurs"))
def test_liste_et_journal(self):
db.creer_code(self.c, ESC + "etiquette", 1)
db.journal(self.c, ESC, None, ESC, ESC)
self.assertNotIn("\x1b", sortie("liste"))
self.assertNotIn("\x1b", sortie("journal"))
def test_generer(self):
self.assertNotIn("\x1b", sortie("generer", "--label", ESC))
def test_serveur_refuse_controle(self):
self.assertTrue(server.a_controle("Jean\x1b[2J"))
self.assertFalse(server.a_controle("Éloïse-Marie"))
if __name__ == "__main__":
unittest.main()
+33
Voir le fichier
@@ -0,0 +1,33 @@
"""Droits des fichiers sensibles (Linux/macOS). Sous Windows les bits POSIX
n'existent pas : le test est ignoré et la protection repose sur le profil
utilisateur (voir README, section Sécurité)."""
import os
import stat
import sys
import tempfile
import unittest
from pathlib import Path
sys.path.insert(0, str(Path(__file__).resolve().parent.parent))
@unittest.skipIf(os.name == "nt", "droits POSIX non applicables sous Windows")
class Droits(unittest.TestCase):
def test_droits(self):
tmp = tempfile.mkdtemp()
os.environ["BETA_DATA"] = str(Path(tmp) / "data")
import db, codes
c = db.connect()
db.creer_code(c, "t")
c.execute("INSERT INTO audit(ts,event) VALUES(1,'x')"); c.commit()
codes.main(["generer", "--label", "x", "--csv"])
mode = lambda p: stat.S_IMODE(os.stat(p).st_mode)
d = Path(os.environ["BETA_DATA"])
self.assertEqual(mode(d), 0o700)
for f in d.iterdir():
self.assertEqual(mode(f), 0o600, f.name)
self.assertTrue((d / "sel.bin").exists() and (d / "codes-emis.csv").exists())
if __name__ == "__main__":
unittest.main()
+384
Voir le fichier
@@ -0,0 +1,384 @@
"""Tests HTTP de la porte d'entrée, des retours et du formulaire (serveur réel, port libre)."""
import base64
import http.client
import json
import os
import sys
import tempfile
import threading
import time
import unittest
from pathlib import Path
sys.path.insert(0, str(Path(__file__).resolve().parent.parent))
os.environ["BETA_DATA"] = str(Path(tempfile.mkdtemp()) / "data")
import db, server # noqa: E402
ADMIN = {"X-Admin": "1", "Host": "admin.jobrunner.fr"}
CRLF = bytes([13, 10])
PNG = "data:image/png;base64," + base64.b64encode(b"\x89PNG\r\n\x1a\n" + b"0" * 50).decode()
class T(unittest.TestCase):
@classmethod
def setUpClass(cls):
cls.conn = db.connect(check_same_thread=False)
server.Handler.timeout = 3
server.Handler.protocol_version = "HTTP/1.0"
cls.srv = server.Serveur(("127.0.0.1", 0), cls.conn)
cls.port = cls.srv.server_address[1]
threading.Thread(target=cls.srv.serve_forever, daemon=True).start()
cls.id, cls.code = db.creer_code(cls.conn, "Testeur", 7)
@classmethod
def tearDownClass(cls):
cls.srv.shutdown()
def req(self, method, path, body=None, cookie=None, headers=None):
c = http.client.HTTPConnection("127.0.0.1", self.port, timeout=10)
h = {"X-Beta": "1", "Content-Type": "application/json"}
h.update(headers or {})
if cookie:
h["Cookie"] = cookie
c.request(method, path, json.dumps(body) if body is not None else None, h)
r = c.getresponse()
data = r.read()
return r.status, r, data
def entrer(self, code=None):
s, r, d = self.req("POST", "/__beta/api/enter", {"code": code or self.code})
ck = (r.getheader("Set-Cookie") or "").split(";")[0]
return s, ck, r
def test_1_sans_code(self):
s, r, _ = self.req("GET", "/app.html")
self.assertEqual((s, r.getheader("Location")), (302, "/__beta/formulaire"))
self.assertEqual(self.req("GET", "/assets/css/app.css")[0], 401)
self.assertEqual(self.req("GET", "/__beta/api/demo")[0], 401)
# La gate redirige vers le formulaire
s_g, r_g, _ = self.req("GET", "/__beta/gate")
self.assertEqual((s_g, r_g.getheader("Location")), (302, "/__beta/formulaire"))
self.assertEqual(self.req("GET", "/__beta/formulaire")[0], 200)
self.assertEqual(self.req("GET", "/assets/fonts/chillax-latin-400-normal.woff2")[0], 200)
def test_1b_traversee_sans_code(self):
chemins = ["/assets/fonts/../../beta/db.py", "/assets/fonts/%2e%2e/%2e%2e/beta/db.py", "/assets/fonts/..%2f..%2fbeta/db.py",
"/assets/fonts/%252e%252e/%252e%252e/beta/db.py", "/assets/img/logo.png/../../../beta/db.py",
"/assets/css/../../beta/server.py", "/assets/fonts/./chillax-latin-400-normal.woff2",
"/assets/fonts/..%5c..%5cbeta%5cdb.py", "/__beta/static/../../db.py", "/__beta/static/%2e%2e/db.py",
"/assets/img/logo-x.png", "/assets/fonts/chillax-latin-400-normal.woff2/../../css/app.css"]
for ch in chemins:
c = http.client.HTTPConnection("127.0.0.1", self.port)
c.putrequest("GET", ch, skip_accept_encoding=True); c.endheaders()
r = c.getresponse(); r.read()
self.assertIn(r.status, (404, 401), ch)
def test_2_csrf(self):
c = http.client.HTTPConnection("127.0.0.1", self.port)
c.request("POST", "/__beta/api/enter", "{}", {"Content-Type": "application/json"})
self.assertEqual(c.getresponse().status, 403)
def test_3_entree_et_acces(self):
s, ck, r = self.entrer(self.code.lower().replace("-", " "))
self.assertEqual(s, 200)
self.assertIn("HttpOnly", r.getheader("Set-Cookie"))
self.assertIn("SameSite=Lax", r.getheader("Set-Cookie"))
s, r, d = self.req("GET", "/app.html", cookie=ck)
self.assertEqual(s, 200)
self.assertIn(b"/__beta/static/beta.js", d)
self.assertIn("connect-src 'self'", r.getheader("Content-Security-Policy"))
for interdit in ("/beta/db.py", "/.git/config", "/docs/conv.nils.md", "/DOCUMENTATION.md", "/package.json",
"/../beta/db.py", "/%2e%2e/beta/db.py", "/beta/data/beta.sqlite"):
self.assertIn(self.req("GET", interdit, cookie=ck)[0], (404, 401), interdit)
s, _, d = self.req("GET", "/__beta/api/demo", cookie=ck)
self.assertEqual(s, 200)
self.assertIn("profiles", json.loads(d))
def test_4_retour(self):
_, ck, _ = self.entrer()
s, _, d = self.req("POST", "/__beta/api/feedback", {"text": "Le bouton est trop petit", "kind": "changer", "page": "/app.html\x1b", "viewport": "375x812", "screenshot": PNG}, ck)
self.assertEqual(s, 200, d)
self.assertTrue(list((db.DATA / "retours").glob("*.png")))
self.assertEqual(self.req("POST", "/__beta/api/feedback", {"text": "x"}, ck)[0], 400)
self.assertEqual(self.req("POST", "/__beta/api/feedback", {"text": "abc", "screenshot": "data:image/png;base64,AAAA"}, ck)[0], 400)
self.assertEqual(self.req("POST", "/__beta/api/feedback", {"text": "abc"})[0], 401)
row = self.conn.execute("SELECT page FROM feedback ORDER BY id DESC").fetchone()
self.assertNotIn("\x1b", row[0])
def test_5_revocation_immediate(self):
i, code = db.creer_code(self.conn, "Jetable", 7)
_, ck, _ = self.entrer(code)
self.assertEqual(self.req("GET", "/__beta/api/me", cookie=ck)[0], 200)
self.conn.execute("UPDATE codes SET revoked_at=? WHERE id=?", (time.time(), i)); self.conn.commit()
self.assertEqual(self.req("GET", "/__beta/api/me", cookie=ck)[0], 401)
self.assertEqual(self.entrer(code)[0], 401)
def test_6_expiration(self):
i, code = db.creer_code(self.conn, "Court", 7)
self.conn.execute("UPDATE codes SET expires_at=? WHERE id=?", (time.time() - 5, i)); self.conn.commit()
self.assertEqual(self.entrer(code)[0], 401)
def test_7_journal(self):
ev = {r[0] for r in self.conn.execute("SELECT event FROM audit")}
self.assertTrue({"code_cree", "entree_ok"} <= ev)
def test_8_formulaire(self):
base = {"nom": "Durand", "prenom": "Zoé", "email": "zoe@example.org", "tel": "06 12 34 56 78", "naissance": "1990-04-02",
"accord_participation": True, "rgpd": True, "confidentialite": True}
s, r, d = self.req("POST", "/__beta/api/tester", base)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertTrue(res.get("ok"))
self.assertEqual(res.get("suite"), "/app.html")
cookie = r.getheader("Set-Cookie")
self.assertTrue(cookie and "jrb_s=" in cookie)
# Accès direct avec le cookie délivré à l'inscription
self.assertEqual(self.req("GET", "/app.html", cookie=cookie)[0], 200)
self.assertEqual(self.req("POST", "/__beta/api/tester", dict(base, naissance="2016-01-01"))[0], 400) # < 15 ans
mineur = dict(base, naissance=f"{time.localtime().tm_year - 16}-01-01", email="mineur@example.org")
self.assertEqual(self.req("POST", "/__beta/api/tester", mineur)[0], 400) # sans accord parental
ok = dict(mineur, parent_nom="Parent Durand", parent_email="p@example.org", accord_parental=True)
self.assertEqual(self.req("POST", "/__beta/api/tester", ok)[0], 200)
self.assertEqual(self.req("POST", "/__beta/api/tester", dict(base, rgpd=False))[0], 400)
self.assertEqual(self.req("POST", "/__beta/api/tester", dict(base, nom="A\x1b[2J"))[0], 400) # contrôle
self.assertEqual(self.req("POST", "/__beta/api/tester", dict(base, email="pas-un-mail"))[0], 400)
def test_8b_client_lent_ne_bloque_pas(self):
import socket
lent = socket.create_connection(("127.0.0.1", self.port))
lent.sendall(b"POST /__beta/api/enter HTTP/1.1"+CRLF+b"Host: x"+CRLF+b"X-Beta: 1"+CRLF+b"Content-Length: 100"+CRLF+CRLF+b"{")
t0 = time.time()
s, _, _ = self.req("GET", "/__beta/healthz")
s2, ck, _ = self.entrer()
self.assertEqual((s, s2), (200, 200))
self.assertLess(time.time() - t0, 2)
lent.close()
def test_8c_saturation_globale_laisse_passer_code_valide(self):
self.conn.execute("DELETE FROM attempts")
for i in range(server.MAX_ECHECS_GLOBAL + 5):
self.conn.execute("INSERT INTO attempts(ts,ip_hash,ok,reason) VALUES(?,?,0,'x')", (time.time(), f"autre{i}"))
self.conn.commit()
s, ck, _ = self.entrer()
self.assertEqual(s, 200)
def test_8d_limites_de_corps_avant_authentification(self):
import socket
for chemin, taille, attendu in (("/__beta/api/enter", 5000, 413), ("/__beta/api/tester", 20000, 413), ("/__beta/api/feedback", 100000, 401), ("/__beta/api/inconnu", 10, 404)):
sk = socket.create_connection(("127.0.0.1", self.port)); sk.settimeout(5)
sk.sendall(("POST " + chemin + " HTTP/1.1").encode() + CRLF + b"Host: x" + CRLF + b"X-Beta: 1" + CRLF + ("Content-Length: %d" % taille).encode() + CRLF + CRLF)
self.assertEqual(sk.recv(100)[9:12], str(attendu).encode(), chemin) # refusé sans lire le corps
sk.close()
def test_8e_limite_atomique_sous_concurrence(self):
self.conn.execute("DELETE FROM attempts"); self.conn.commit()
res = []
def tente():
res.append(self.entrer("JRB-ZZZZ-ZZZZ-ZZZZ")[0])
th = [threading.Thread(target=tente) for _ in range(20)]
[x.start() for x in th]; [x.join() for x in th]
self.assertLessEqual(res.count(401), server.MAX_ECHECS_IP, res) # jamais plus de N essais effectifs
self.assertGreaterEqual(res.count(429), 20 - server.MAX_ECHECS_IP - 4)
self.conn.execute("DELETE FROM attempts"); self.conn.commit()
def test_8f_delai_total_goutte_a_goutte(self):
import socket
server.DELAI_TOTAL = 2
try:
sk = socket.create_connection(("127.0.0.1", self.port)); sk.settimeout(8)
sk.sendall(b"GET /__beta/healthz HTTP/1.1" + CRLF + b"Host: x") # en-têtes jamais terminés
t0 = time.time()
fin = False
for _ in range(6):
try:
sk.sendall(b"X"); time.sleep(0.5)
except OSError:
fin = True; break
self.assertTrue(fin or sk.recv(10) == b"")
self.assertLess(time.time() - t0, 6)
finally:
server.DELAI_TOTAL = 20
def test_8g_pas_de_keepalive(self):
s, r, _ = self.req("GET", "/__beta/healthz")
self.assertEqual(r.getheader("Connection"), "close")
def test_8h_delai_hors_semaphore_et_concurrence_par_ip(self):
self.conn.execute("DELETE FROM attempts"); self.conn.commit()
old, oldd = server.MAX_CONC_IP, server.DELAI_ECHEC
server.MAX_CONC_IP, server.DELAI_ECHEC = 1, 1.5
try:
th = threading.Thread(target=lambda: self.entrer("JRB-AAAA-AAAA-AAAA")); th.start()
time.sleep(0.4) # le raté dort (1,5 s) mais ne tient plus aucune place
t0 = time.time(); s, _, _ = self.entrer()
self.assertEqual(s, 200); self.assertLess(time.time() - t0, 1.0)
th.join()
finally:
server.MAX_CONC_IP, server.DELAI_ECHEC = old, oldd
self.assertEqual(self.srv.conc, {}) # compteurs nettoyés
def test_9_limite_tentatives_en_dernier(self):
self.conn.execute("DELETE FROM attempts"); self.conn.commit()
for _ in range(server.MAX_ECHECS_IP):
self.assertEqual(self.entrer("JRB-AAAA-AAAA-AAAA")[0], 401)
s, _, r = self.entrer() # même le bon code est refusé pendant le blocage
self.assertEqual(s, 429)
self.assertTrue(r.getheader("Retry-After"))
def test_admin_api(self):
# 1. Sans header X-Admin : refus 403
s, _, _ = self.req("POST", "/_admin/api/codes/creer", {"label": "Test 1"})
self.assertEqual(s, 403)
s, _, _ = self.req("GET", "/_admin/api/codes/liste")
self.assertEqual(s, 403)
# 2. Avec header X-Admin : succès 200
s, _, d = self.req("POST", "/_admin/api/codes/creer", {"label": "Testeur Admin", "jours": 14}, headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertTrue(res.get("ok"))
code = res.get("code")
self.assertTrue(code and code.startswith("JRB-"))
self.assertEqual(res.get("label"), "Testeur Admin")
# 3. Liste des codes
s, _, d = self.req("GET", "/_admin/api/codes/liste", headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertTrue(res.get("ok"))
labels = [c["label"] for c in res.get("codes", [])]
self.assertIn("Testeur Admin", labels)
code_id = res["codes"][0]["id"]
# 4. Supprimer le code
s, _, d = self.req("POST", "/_admin/api/codes/supprimer", {"id": code_id}, headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertTrue(res.get("ok"))
self.assertEqual(res.get("id"), code_id)
# Vérification qu'il n'est plus dans la liste
s, _, d = self.req("GET", "/_admin/api/codes/liste", headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
labels_after = [c["label"] for c in res.get("codes", [])]
self.assertNotIn("Testeur Admin", labels_after)
# 5. Liste des testeurs (inscriptions)
s, _, d = self.req("GET", "/_admin/api/candidatures/liste", headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertTrue(res.get("ok"))
cands = res.get("candidatures", [])
self.assertIsInstance(cands, list)
self.assertTrue(len(cands) >= 1)
testeur = cands[0]
self.assertTrue(testeur.get("ip"))
self.assertTrue(testeur.get("expire_ip_at") > 0)
# 6. Suspendre le testeur
tid = testeur["id"]
s, _, d = self.req("POST", "/_admin/api/testeurs/statut", {"id": tid, "actif": 0}, headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertEqual(res.get("actif"), 0)
# 7. Réactiver le testeur
s, _, d = self.req("POST", "/_admin/api/testeurs/statut", {"id": tid, "actif": 1}, headers=ADMIN)
self.assertEqual(s, 200)
res = json.loads(d.decode())
self.assertEqual(res.get("actif"), 1)
# 8. Supprimer le testeur
s, _, d = self.req("POST", "/_admin/api/testeurs/supprimer", {"id": tid}, headers=ADMIN)
self.assertEqual(s, 200)
def test_admin_refuse_depuis_le_site_public(self):
# Le vhost public de Caddy transmet tout en-tête du visiteur : X-Admin seul ne doit rien ouvrir.
for host in ("jobrunner.fr", "beta.jobrunner.fr", "www.jobrunner.fr", "127.0.0.1", "admin.jobrunner.fr.evil.com", "[::1]"):
h = {"X-Admin": "1", "Host": host}
self.assertEqual(self.req("GET", "/_admin/api/candidatures/liste", headers=h)[0], 403, host)
self.assertEqual(self.req("GET", "/_admin/api/codes/liste", headers=h)[0], 403, host)
self.assertEqual(self.req("POST", "/_admin/api/codes/creer", {"label": "Pirate"}, headers=h)[0], 403, host)
self.assertEqual(self.req("POST", "/_admin/api/testeurs/supprimer", {"id": 1}, headers=h)[0], 403, host)
self.assertEqual(self.req("GET", "/_admin/api/codes/liste", headers={"X-Admin": "1", "Host": "ADMIN.jobrunner.fr:443"})[0], 200)
self.assertEqual(self.req("GET", "/_admin/api/codes/liste", headers={"Host": "admin.jobrunner.fr"})[0], 403)
def test_8i_logout_post_seulement(self):
_, ck, _ = self.entrer()
self.assertEqual(self.req("GET", "/__beta/logout", cookie=ck)[0], 405)
self.assertEqual(self.req("GET", "/__beta/api/me", cookie=ck)[0], 200) # GET n'a rien coupé
self.assertEqual(self.req("POST", "/__beta/logout", cookie=ck, headers={"X-Beta": "0"})[0], 403) # sans X-Beta
s, r, _ = self.req("POST", "/__beta/logout", cookie=ck)
self.assertEqual(s, 200)
self.assertIn("Max-Age=0", r.getheader("Set-Cookie"))
self.assertEqual(self.req("GET", "/__beta/api/me", cookie=ck)[0], 401)
def test_effacement_testeur_avec_retours_et_captures(self):
base = {"nom": "Efface", "prenom": "Moi", "email": "efface@example.org", "tel": "06 00 00 00 00", "naissance": "1991-01-01",
"accord_participation": True, "rgpd": True, "confidentialite": True}
s, r, _ = self.req("POST", "/__beta/api/tester", base)
self.assertEqual(s, 200)
ck = r.getheader("Set-Cookie").split(";")[0]
s, _, d = self.req("POST", "/__beta/api/feedback", {"text": "retour a effacer", "screenshot": PNG}, ck)
self.assertEqual(s, 200, d)
fid = json.loads(d)["id"]
row = self.conn.execute("SELECT code_id, tester_id, shot FROM feedback WHERE id=?", (fid,)).fetchone()
self.assertIsNone(row[0]) # plus d'id de testeur rangé dans code_id
tid = row[1]
capture = db.DATA / "retours" / row[2]
self.assertTrue(capture.exists())
s, _, _ = self.req("POST", "/_admin/api/testeurs/supprimer", {"id": tid}, headers=ADMIN)
self.assertEqual(s, 200)
self.assertFalse(capture.exists())
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM feedback WHERE id=?", (fid,)).fetchone()[0], 0)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM testers WHERE id=?", (tid,)).fetchone()[0], 0)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM sessions WHERE tester_id=?", (tid,)).fetchone()[0], 0)
def test_purge_simulation_puis_application(self):
now = time.time()
vieux = now - 400 * 86400
cur = self.conn.execute("INSERT INTO testers(ts,nom,prenom,email,actif) VALUES(?,?,?,?,1)", (vieux, "Vieux", "T", "v@example.org"))
tid = cur.lastrowid
self.conn.execute("INSERT INTO feedback(ts,code_id,tester_id,text) VALUES(?,?,?,?)", (vieux, None, tid, "ancien"))
self.conn.execute("INSERT INTO attempts(ts,ip_hash,ok) VALUES(?,?,0)", (vieux, "x"))
self.conn.execute("INSERT INTO audit(ts,event) VALUES(?,?)", (vieux, "ancien"))
self.conn.commit()
avant = now - 200 * 86400
b = db.purger(self.conn, avant) # simulation par défaut
self.assertGreaterEqual(b["testeurs"], 1)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM testers WHERE id=?", (tid,)).fetchone()[0], 1)
db.purger(self.conn, avant, simulation=False)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM testers WHERE id=?", (tid,)).fetchone()[0], 0)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM feedback WHERE tester_id=?", (tid,)).fetchone()[0], 0)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM attempts WHERE ts<?", (avant,)).fetchone()[0], 0)
self.assertEqual(self.conn.execute("SELECT COUNT(*) FROM audit WHERE event='ancien'").fetchone()[0], 0)
self.assertGreater(self.conn.execute("SELECT COUNT(*) FROM testers").fetchone()[0], 0) # les récents restent
def test_8j_plafond_captures(self):
i, code = db.creer_code(self.conn, "Captures", 7)
_, ck, _ = self.entrer(code)
ancien = server.MAX_CAPTURES_JOUR
server.MAX_CAPTURES_JOUR = 2
try:
for _ in range(2):
self.assertEqual(self.req("POST", "/__beta/api/feedback", {"text": "capture ok", "screenshot": PNG}, ck)[0], 200)
s, _, d = self.req("POST", "/__beta/api/feedback", {"text": "capture de trop", "screenshot": PNG}, ck)
self.assertEqual(s, 429, d)
self.assertEqual(self.req("POST", "/__beta/api/feedback", {"text": "texte seul toujours accepte"}, ck)[0], 200)
finally:
server.MAX_CAPTURES_JOUR = ancien
ancien = server.MIN_LIBRE_OCTETS
server.MIN_LIBRE_OCTETS = 10 ** 18 # disque « plein »
try:
_, ck2, _ = self.entrer(db.creer_code(self.conn, "Disque", 7)[1])
self.assertEqual(self.req("POST", "/__beta/api/feedback", {"text": "disque plein", "screenshot": PNG}, ck2)[0], 507)
finally:
server.MIN_LIBRE_OCTETS = ancien
if __name__ == "__main__":
unittest.main(verbosity=2)
+379 -1
Voir le fichier
@@ -49,6 +49,97 @@
</div> </div>
</section> </section>
<!-- ================= GESTION DE LA BÊTA (INSCRIPTIONS LIBRES & IP 13 MOIS) ================= -->
<section class="beta-zone">
<div class="beta-zone-entete">
<h2>Inscriptions & Accès Bêta <span class="compte" id="compte-total-testeurs">0</span></h2>
<a class="lien-externe" href="https://jobrunner.fr" target="_blank" rel="noopener">Ouvrir jobrunner.fr ↗</a>
</div>
<div class="carte-gestion-beta">
<!-- Bloc principal : Testeurs inscrits en direct -->
<div>
<div class="liste-codes-entete">
<div>
<h3 style="margin:0 0 4px;font-size:18px;">👥 Testeurs inscrits (accès libre)</h3>
<p style="margin:0;font-size:13.5px;color:var(--doux);">Tout utilisateur ayant rempli le formulaire reçoit un accès immédiat. Les adresses IP sont conservées 13 mois (obligation légale LCEN).</p>
</div>
<button type="button" id="btn-rafraichir-candidatures" class="btn-rafraichir" title="Actualiser">↻ Actualiser</button>
</div>
<div id="conteneur-tableau-candidatures" class="tableau-scroll" style="margin-top:16px;">
<p class="chargement">Chargement des testeurs...</p>
</div>
</div>
<!-- Bloc secondaire : Générateur de codes d'exception (manuel) -->
<div class="bloc-secondaire">
<details>
<summary style="cursor:pointer;font-weight:700;font-size:14.5px;color:var(--texte);outline:none;user-select:none;">
⚙️ Créer un code d'accès spécial (invitation manuelle / sans formulaire)
</summary>
<div style="margin-top:18px;">
<form id="form-creer-code" class="form-generateur" autocomplete="off">
<div class="ligne-form">
<div class="champ">
<label for="code-label">Nom ou référence</label>
<input type="text" id="code-label" placeholder="Ex. Partenaire Spécial">
</div>
<div class="champ">
<label for="code-duree">Validité</label>
<select id="code-duree">
<option value="30" selected>30 jours</option>
<option value="60">60 jours</option>
<option value="90">90 jours</option>
<option value="0">Illimitée</option>
</select>
</div>
<button type="submit" id="btn-soumettre-code" class="btn-creer">
<span>Créer le code</span>
<span aria-hidden="true">→</span>
</button>
</div>
<div id="code-erreur" class="alerte-erreur" style="display:none;"></div>
</form>
<!-- Encart du code généré -->
<div id="zone-nouveau-code" class="zone-nouveau-code" style="display:none;">
<div class="nouveau-code-entete">
<span class="badge-succes">✓ Code prêt à l'emploi</span>
<span id="label-cree-affiche" class="label-testeur"></span>
</div>
<div class="code-valeur-ligne">
<code id="code-genere-valeur" class="code-gros">JRB-XXXX-XXXX-XXXX</code>
<button type="button" id="btn-copier-code-seul" class="btn-copier">
<span>📋 Copier le code</span>
</button>
</div>
<div class="whatsapp-partage">
<div class="whatsapp-partage-titre">
<span>💬 Message d'invitation prêt à envoyer :</span>
<button type="button" id="btn-copier-msg" class="btn-copier-petit">
<span>Copier le message</span>
</button>
</div>
<textarea id="texte-msg-whatsapp" readonly rows="3" class="whatsapp-champ"></textarea>
</div>
</div>
<!-- Historique des codes manuels -->
<div class="historique-codes">
<div class="liste-codes-entete">
<h4>Codes d'accès manuels émis <span class="compte" id="compte-codes">0</span></h4>
<button type="button" id="btn-rafraichir-codes" class="btn-rafraichir" title="Actualiser">↻ Actualiser</button>
</div>
<div id="conteneur-tableau-codes" class="tableau-scroll">
<p class="chargement">Chargement des codes en cours...</p>
</div>
</div>
</div>
</details>
</div>
</div>
</section>
<section class="construction"> <section class="construction">
<h2>En construction <span class="compte">5</span></h2> <h2>En construction <span class="compte">5</span></h2>
<div class="grille petite"> <div class="grille petite">
@@ -88,5 +179,292 @@
<footer>Jobrunner · espace projet réservé</footer> <footer>Jobrunner · espace projet réservé</footer>
</div> </div>
<script>
(function() {
const form = document.getElementById('form-creer-code');
const inputLabel = document.getElementById('code-label');
const selectDuree = document.getElementById('code-duree');
const btnSoumettre = document.getElementById('btn-soumettre-code');
const errBox = document.getElementById('code-erreur');
const zoneResultat = document.getElementById('zone-nouveau-code');
const labelAffiche = document.getElementById('label-cree-affiche');
const codeAffiche = document.getElementById('code-genere-valeur');
const btnCopierCode = document.getElementById('btn-copier-code-seul');
const btnCopierMsg = document.getElementById('btn-copier-msg');
const whatsappTexte = document.getElementById('texte-msg-whatsapp');
const conteneurTableauCodes = document.getElementById('conteneur-tableau-codes');
const btnRafraichirCodes = document.getElementById('btn-rafraichir-codes');
const compteCodesEl = document.getElementById('compte-codes');
const conteneurTableauCandidatures = document.getElementById('conteneur-tableau-candidatures');
const btnRafraichirCandidatures = document.getElementById('btn-rafraichir-candidatures');
const compteTotalTesteurs = document.getElementById('compte-total-testeurs');
let dernierCode = '';
function fmtDate(ts) {
if (!ts) return '-';
const d = new Date(ts * 1000);
return d.toLocaleDateString('fr-FR', { day: '2-digit', month: '2-digit', year: 'numeric' });
}
function fmtDateHeure(ts) {
if (!ts) return '-';
const d = new Date(ts * 1000);
return d.toLocaleDateString('fr-FR', { day: '2-digit', month: '2-digit', year: 'numeric' }) +
' à ' + d.toLocaleTimeString('fr-FR', { hour: '2-digit', minute: '2-digit' });
}
function escapeHtml(str) {
const div = document.createElement('div');
div.textContent = str || '';
return div.innerHTML;
}
function escapeJs(str) {
return (str || '').replace(/\\/g, '\\\\').replace(/'/g, "\\'");
}
// --- Gestion des testeurs inscrits (libre) ---
async function chargerTesteurs() {
try {
const res = await fetch('/_admin/api/candidatures/liste');
if (!res.ok) {
conteneurTableauCandidatures.innerHTML = '<p class="chargement" style="color:#A0554B;">Impossible de charger les inscrits (' + res.status + ').</p>';
return;
}
const data = await res.json();
afficherTableauTesteurs(data.candidatures || []);
} catch (e) {
conteneurTableauCandidatures.innerHTML = '<p class="chargement">Impossible de contacter le serveur.</p>';
}
}
function afficherTableauTesteurs(liste) {
if (compteTotalTesteurs) compteTotalTesteurs.textContent = liste.length;
if (!liste.length) {
conteneurTableauCandidatures.innerHTML = '<p class="chargement">Aucun testeur inscrit pour le moment. Partagez le lien <b>https://jobrunner.fr</b> !</p>';
return;
}
let html = '<table class="table-codes"><thead><tr>' +
'<th>Date</th><th>Testeur</th><th>Contact</th><th>IP (LCEN 13 mois)</th><th>Statut</th><th>Actions</th>' +
'</tr></thead><tbody>';
for (const item of liste) {
const ageBadge = item.mineur
? '<span class="badge-age mineur">15-17 ans (mineur)</span>'
: '<span class="badge-age">Majeur</span>';
const parentHtml = (item.mineur && item.parent_nom)
? '<span class="parent-info">Resp. légal : ' + escapeHtml(item.parent_nom) + ' (' + escapeHtml(item.parent_email || '') + ')</span>'
: '';
const ipAffichage = item.ip
? '<span class="badge-ip">' + escapeHtml(item.ip) + '</span>' +
(item.expire_ip_at ? '<span class="ip-purge-info">Purge le ' + fmtDate(item.expire_ip_at) + '</span>' : '')
: '<span style="color:var(--doux);font-size:12px;">Non renseignée</span>';
const statutBadge = item.actif
? '<span class="badge-statut actif">Actif</span>'
: '<span class="badge-statut revoque">Suspendu</span>';
const btnToggle = item.actif
? '<button type="button" class="btn-action-toggle suspendre" onclick="window.jobrunnerBeta.changerStatut(' + item.id + ', false, \'' + escapeJs(item.prenom + ' ' + item.nom) + '\')">Suspendre</button>'
: '<button type="button" class="btn-action-toggle reactiver" onclick="window.jobrunnerBeta.changerStatut(' + item.id + ', true, \'' + escapeJs(item.prenom + ' ' + item.nom) + '\')">Réactiver</button>';
html += '<tr>' +
'<td>' + fmtDateHeure(item.ts) + '</td>' +
'<td><strong>' + escapeHtml(item.prenom) + ' ' + escapeHtml(item.nom) + '</strong> ' + ageBadge + parentHtml + '</td>' +
'<td><div class="contact-ligne">' +
'<a href="mailto:' + escapeHtml(item.email) + '">' + escapeHtml(item.email) + '</a>' +
'<a href="tel:' + escapeHtml(item.tel) + '">' + escapeHtml(item.tel) + '</a>' +
'</div></td>' +
'<td>' + ipAffichage + '</td>' +
'<td>' + statutBadge + '</td>' +
'<td><div class="actions-cell">' +
btnToggle +
'<button type="button" class="btn-action-suppr" onclick="window.jobrunnerBeta.supprimerTesteur(' + item.id + ', \'' + escapeJs(item.prenom + ' ' + item.nom) + '\')">Supprimer</button>' +
'</div></td>' +
'</tr>';
}
html += '</tbody></table>';
conteneurTableauCandidatures.innerHTML = html;
}
// --- Actions globales exposées ---
window.jobrunnerBeta = {
changerStatut: async function(id, actif, nom) {
const action = actif ? 'réactiver' : 'suspendre';
if (!confirm('Voulez-vous ' + action + ' l\'accès de "' + nom + '" ?')) return;
try {
const res = await fetch('/_admin/api/testeurs/statut', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ id: id, actif: actif })
});
const data = await res.json().catch(() => ({}));
if (res.ok && data.ok) {
chargerTesteurs();
} else {
alert(data.erreur || 'Erreur lors du changement de statut.');
}
} catch (e) {
alert('Erreur réseau.');
}
},
supprimerTesteur: async function(id, nom) {
if (!confirm('Supprimer définitivement le compte et les données de "' + nom + '" ?')) return;
try {
const res = await fetch('/_admin/api/testeurs/supprimer', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ id: id })
});
const data = await res.json().catch(() => ({}));
if (res.ok && data.ok) {
chargerTesteurs();
} else {
alert(data.erreur || 'Erreur lors de la suppression.');
}
} catch (e) {
alert('Erreur réseau.');
}
},
supprimerCode: async function(id, label) {
if (!confirm('Supprimer définitivement le code de "' + label + '" ?')) return;
try {
const res = await fetch('/_admin/api/codes/supprimer', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ id: id })
});
const data = await res.json().catch(() => ({}));
if (res.ok && data.ok) {
chargerCodes();
} else {
alert(data.erreur || 'Erreur lors de la suppression.');
}
} catch (e) {
alert('Erreur réseau.');
}
}
};
// --- Gestion des codes d'exception ---
async function chargerCodes() {
try {
const res = await fetch('/_admin/api/codes/liste');
if (!res.ok) {
conteneurTableauCodes.innerHTML = '<p class="chargement" style="color:#A0554B;">Impossible de charger les codes (' + res.status + ').</p>';
return;
}
const data = await res.json();
afficherTableauCodes(data.codes || []);
} catch (e) {
conteneurTableauCodes.innerHTML = '<p class="chargement">Impossible de contacter le serveur.</p>';
}
}
function afficherTableauCodes(codes) {
if (compteCodesEl) compteCodesEl.textContent = codes.length;
if (!codes.length) {
conteneurTableauCodes.innerHTML = '<p class="chargement">Aucun code d\'exception émis.</p>';
return;
}
let html = '<table class="table-codes"><thead><tr><th>ID</th><th>Référence</th><th>Créé le</th><th>Expire</th><th>Utilisations</th><th>Statut</th><th>Action</th></tr></thead><tbody>';
for (const c of codes) {
const usesHtml = c.uses > 0
? '<span class="badge-usages actif">' + c.uses + ' connexion' + (c.uses > 1 ? 's' : '') + '</span>'
: '<span class="badge-usages">0</span>';
html += '<tr>' +
'<td>#' + c.id + '</td>' +
'<td><strong>' + escapeHtml(c.label) + '</strong></td>' +
'<td>' + fmtDate(c.created_at) + '</td>' +
'<td>' + (c.expires_at ? fmtDate(c.expires_at) : 'Illimité') + '</td>' +
'<td>' + usesHtml + '</td>' +
'<td><span class="badge-statut ' + (c.status === 'actif' ? 'actif' : (c.status === 'révoqué' ? 'revoque' : 'expire')) + '">' + escapeHtml(c.status) + '</span></td>' +
'<td><button type="button" class="btn-action-suppr" onclick="window.jobrunnerBeta.supprimerCode(' + c.id + ', \'' + escapeJs(c.label) + '\')">Supprimer</button></td>' +
'</tr>';
}
html += '</tbody></table>';
conteneurTableauCodes.innerHTML = html;
}
form.addEventListener('submit', async function(e) {
e.preventDefault();
errBox.style.display = 'none';
errBox.textContent = '';
const label = inputLabel.value.trim();
const jours = parseInt(selectDuree.value, 10);
if (!label) {
errBox.textContent = 'Veuillez saisir un nom ou référence.';
errBox.style.display = 'block';
return;
}
btnSoumettre.disabled = true;
btnSoumettre.querySelector('span').textContent = 'Génération...';
try {
const res = await fetch('/_admin/api/codes/creer', {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({ label: label, jours: jours })
});
const data = await res.json().catch(() => ({}));
if (res.ok && data.ok) {
dernierCode = data.code;
labelAffiche.textContent = data.label;
codeAffiche.textContent = data.code;
const msg = "Salut " + label + " ! Voici ton accès spécial pour tester JobRunner en avant-première : " + data.code + "\n\nRendez-vous sur https://jobrunner.fr pour te connecter.";
whatsappTexte.value = msg;
zoneResultat.style.display = 'block';
inputLabel.value = '';
chargerCodes();
} else {
errBox.textContent = data.erreur || 'Erreur lors de la création du code.';
errBox.style.display = 'block';
}
} catch (err) {
errBox.textContent = 'Erreur réseau.';
errBox.style.display = 'block';
} finally {
btnSoumettre.disabled = false;
btnSoumettre.querySelector('span').textContent = 'Créer le code';
}
});
btnCopierCode.addEventListener('click', function() {
if (!dernierCode) return;
navigator.clipboard.writeText(dernierCode).then(() => {
const span = btnCopierCode.querySelector('span');
span.textContent = '✓ Code copié !';
setTimeout(() => { span.textContent = '📋 Copier le code'; }, 2000);
});
});
btnCopierMsg.addEventListener('click', function() {
navigator.clipboard.writeText(whatsappTexte.value).then(() => {
const span = btnCopierMsg.querySelector('span');
span.textContent = '✓ Message copié !';
setTimeout(() => { span.textContent = 'Copier le message'; }, 2000);
});
});
btnRafraichirCodes.addEventListener('click', chargerCodes);
btnRafraichirCandidatures.addEventListener('click', chargerTesteurs);
chargerTesteurs();
chargerCodes();
})();
</script>
</body> </body>
</html> </html>