Téléverser les fichiers vers "workstation-setup/src"

This commit is contained in:
2026-08-19 17:01:20 +02:00
parent 0f76709f6c
commit 68c69c7713
3 changed files with 92 additions and 61 deletions
+55 -28
View File
@@ -17,9 +17,9 @@ Kirigami.ApplicationWindow {
property var steps: [
{ "title": "Bienvenue", "subtitle": "Première connexion" },
{ "title": "Mot de passe", "subtitle": "Protection LUKS2" },
{ "title": "YubiKey", "subtitle": "Création du PIN" },
{ "title": "Association", "subtitle": "Déverrouillage FIDO2" },
{ "title": "Mot de passe", "subtitle": "Protection des données" },
{ "title": "YubiKey", "subtitle": "Création du code PIN" },
{ "title": "Association", "subtitle": "Association de la clé" },
{ "title": "Terminé", "subtitle": "Poste prêt" }
]
@@ -126,18 +126,20 @@ Kirigami.ApplicationWindow {
component PrimaryButton: Controls.Button {
id: control
implicitHeight: 48
implicitWidth: 180
leftPadding: 24
rightPadding: 24
implicitHeight: 52
leftPadding: 26
rightPadding: 26
implicitWidth: Math.max(210, buttonLabel.implicitWidth + leftPadding + rightPadding)
contentItem: Controls.Label {
id: buttonLabel
text: control.text
color: "white"
font.pixelSize: 15
font.weight: Font.DemiBold
horizontalAlignment: Text.AlignHCenter
verticalAlignment: Text.AlignVCenter
wrapMode: Text.NoWrap
}
background: Rectangle {
@@ -291,7 +293,7 @@ Kirigami.ApplicationWindow {
font.weight: Font.Bold
}
Controls.Label {
text: "Provisioning sécurisé"
text: "Configuration sécurisée"
color: "#b9cee5"
font.pixelSize: 12
}
@@ -410,13 +412,29 @@ Kirigami.ApplicationWindow {
}
}
StackLayout {
Item {
id: pageViewport
Layout.fillWidth: true
Layout.fillHeight: true
currentIndex: root.currentStep
clip: true
Row {
id: pageStrip
height: parent.height
spacing: 0
x: -root.currentStep * pageViewport.width
Behavior on x {
NumberAnimation {
duration: 330
easing.type: Easing.OutCubic
}
}
// 0 - Bienvenue
Item {
width: pageViewport.width
height: pageViewport.height
ColumnLayout {
anchors.fill: parent
spacing: 20
@@ -432,7 +450,7 @@ Kirigami.ApplicationWindow {
Controls.Label {
Layout.maximumWidth: 720
Layout.alignment: Qt.AlignHCenter
text: "Votre espace personnel est déjà protégé par un volume LUKS2. Il reste à remplacer le mot de passe temporaire et à préparer votre YubiKey."
text: "Votre espace personnel est déjà chiffré. Il reste à remplacer le mot de passe temporaire et à préparer votre YubiKey."
wrapMode: Text.WordWrap
horizontalAlignment: Text.AlignHCenter
color: "#64748b"
@@ -443,7 +461,7 @@ Kirigami.ApplicationWindow {
Layout.maximumWidth: 720
Layout.alignment: Qt.AlignHCenter
iconText: "🔐"
text: "À la fin, votre home pourra être déverrouillé soit avec votre mot de passe personnel, soit avec votre YubiKey et son PIN."
text: "À la fin, vous pourrez ouvrir votre espace personnel soit avec votre mot de passe, soit avec votre YubiKey et son code PIN."
}
Item { Layout.fillHeight: true }
PrimaryButton {
@@ -459,6 +477,8 @@ Kirigami.ApplicationWindow {
// 1 - Mot de passe
Item {
width: pageViewport.width
height: pageViewport.height
ColumnLayout {
anchors.fill: parent
spacing: 16
@@ -471,7 +491,7 @@ Kirigami.ApplicationWindow {
}
Controls.Label {
Layout.fillWidth: true
text: "Ce mot de passe reste votre solution de secours si la YubiKey est oubliée ou indisponible. Le changement est appliqué directement à systemd-homed et au chiffrement LUKS2."
text: "Ce mot de passe reste votre solution de secours si la YubiKey est oubliée ou indisponible."
wrapMode: Text.WordWrap
color: "#64748b"
font.pixelSize: 14
@@ -523,7 +543,7 @@ Kirigami.ApplicationWindow {
PrimaryButton {
Layout.alignment: Qt.AlignRight
text: provisioning.busy ? "Modification…" : "Modifier le mot de passe"
text: provisioning.busy ? "Modification…" : "Valider le mot de passe"
enabled: root.passwordStepValid && !provisioning.busy
onClicked: {
root.operationError = ""
@@ -541,6 +561,8 @@ Kirigami.ApplicationWindow {
// 2 - PIN YubiKey
Item {
width: pageViewport.width
height: pageViewport.height
ColumnLayout {
anchors.fill: parent
spacing: 16
@@ -553,7 +575,7 @@ Kirigami.ApplicationWindow {
}
Controls.Label {
Layout.fillWidth: true
text: "Branchez une seule YubiKey vierge puis choisissez son premier PIN FIDO2. Aucun PIN temporaire n'est utilisé."
text: "Branchez une seule YubiKey vierge puis choisissez son code PIN. Aucun code PIN temporaire n'est utilisé."
wrapMode: Text.WordWrap
color: "#64748b"
font.pixelSize: 14
@@ -561,13 +583,13 @@ Kirigami.ApplicationWindow {
InfoBox {
iconText: "☝"
text: "La clé doit sortir d'un reset FIDO2 et ne posséder aucun PIN. Cette étape ne crée aucun fichier u2f-mappings."
text: "La YubiKey doit être vierge ou avoir été réinitialisée. Elle ne doit pas déjà posséder de code PIN."
}
Item { Layout.preferredHeight: 8 }
FieldLabel { text: "Nouveau PIN FIDO2" }
FieldLabel { text: "Nouveau code PIN" }
SecretField { id: newPin }
FieldLabel { text: "Confirmation du PIN" }
FieldLabel { text: "Confirmation du code PIN" }
SecretField { id: confirmPin }
ErrorBox { }
@@ -575,7 +597,7 @@ Kirigami.ApplicationWindow {
PrimaryButton {
Layout.alignment: Qt.AlignRight
text: provisioning.busy ? "Initialisation…" : "Créer le PIN"
text: provisioning.busy ? "Initialisation…" : "Créer le code PIN"
enabled: root.pinStepValid && !provisioning.busy
onClicked: {
root.operationError = ""
@@ -591,19 +613,21 @@ Kirigami.ApplicationWindow {
// 3 - Association FIDO2 au home
Item {
width: pageViewport.width
height: pageViewport.height
ColumnLayout {
anchors.fill: parent
spacing: 16
Controls.Label {
text: "Associez la YubiKey à votre home chiffré"
text: "Associez la YubiKey à votre espace personnel"
color: "#0f172a"
font.pixelSize: 28
font.weight: Font.Bold
}
Controls.Label {
Layout.fillWidth: true
text: "systemd-homed va ajouter la YubiKey comme second moyen de déverrouillage du volume LUKS2. Votre mot de passe personnel reste valide en secours."
text: "La YubiKey sera ajoutée comme second moyen d'ouvrir votre espace personnel chiffré. Votre mot de passe reste utilisable en secours."
wrapMode: Text.WordWrap
color: "#64748b"
font.pixelSize: 14
@@ -611,13 +635,13 @@ Kirigami.ApplicationWindow {
InfoBox {
iconText: "🔐"
text: "Saisissez le mot de passe que vous venez de choisir et le PIN de la YubiKey. Aucune recovery key n'est demandée dans ce workflow."
text: "Saisissez le mot de passe que vous venez de choisir et le code PIN de la YubiKey."
}
InfoBox {
visible: !provisioning.busy
iconText: "☝"
text: "Après avoir lancé l'association, l'assistant vous indiquera précisément quand toucher la YubiKey. Plusieurs touchers peuvent être nécessaires."
text: "Après avoir lancé l'association, suivez les indications affichées à l'écran. La YubiKey peut demander plusieurs touchers."
}
Rectangle {
@@ -665,7 +689,7 @@ Kirigami.ApplicationWindow {
Layout.fillWidth: true
text: provisioning.fidoTouchRequired
? "TOUCHEZ LA YUBIKEY MAINTENANT"
: "Association FIDO2 en cours"
: "Association de la YubiKey en cours"
wrapMode: Text.WordWrap
color: provisioning.fidoTouchRequired ? "#9a3412" : "#1d4ed8"
font.pixelSize: provisioning.fidoTouchRequired ? 18 : 15
@@ -687,7 +711,7 @@ Kirigami.ApplicationWindow {
Item { Layout.preferredHeight: 8 }
FieldLabel { text: "Votre mot de passe personnel actuel" }
SecretField { id: fidoPassword }
FieldLabel { text: "PIN de la YubiKey" }
FieldLabel { text: "Code PIN de la YubiKey" }
SecretField { id: fidoPin }
ErrorBox { }
@@ -711,6 +735,8 @@ Kirigami.ApplicationWindow {
// 4 - Terminé
Item {
width: pageViewport.width
height: pageViewport.height
ColumnLayout {
anchors.fill: parent
spacing: 18
@@ -745,7 +771,7 @@ Kirigami.ApplicationWindow {
Controls.Label {
Layout.maximumWidth: 720
Layout.alignment: Qt.AlignHCenter
text: "Votre mot de passe personnel protège le home LUKS2 et votre YubiKey est désormais enrôlée dans systemd-homed. Vous pourrez ouvrir votre session avec le mot de passe ou avec la YubiKey + PIN."
text: "Votre espace personnel est chiffré et votre YubiKey est prête. Vous pourrez ouvrir votre session avec votre mot de passe ou avec votre YubiKey et son code PIN."
wrapMode: Text.WordWrap
horizontalAlignment: Text.AlignHCenter
color: "#64748b"
@@ -757,7 +783,7 @@ Kirigami.ApplicationWindow {
Layout.maximumWidth: 720
Layout.alignment: Qt.AlignHCenter
iconText: "✓"
text: "Aucun u2f-mappings n'est utilisé. Les données FIDO2 nécessaires au déverrouillage sont gérées par systemd-homed."
text: "Votre configuration sécurisée est terminée. Conservez votre YubiKey avec vous et mémorisez son code PIN."
}
Item { Layout.fillHeight: true }
@@ -770,7 +796,8 @@ Kirigami.ApplicationWindow {
}
}
}
}
} // Row pageStrip
} // pageViewport
}
}
}