From 83f571b226e6412dd848840515634bc79b6944a3 Mon Sep 17 00:00:00 2001 From: TekH Date: Fri, 13 Feb 2026 14:40:45 +0100 Subject: [PATCH] Add 2FA registration localization and update Reg.cshtml Added resource entries for 2FA registration steps and instructions in de-DE, en-US, and fr-FR. Updated Reg.cshtml to use localized strings, replacing hardcoded text for improved internationalization. --- .../Resources/Resource.de-DE.resx | 33 +++++++++++++++++++ .../Resources/Resource.en-US.resx | 33 +++++++++++++++++++ .../Resources/Resource.fr-FR.resx | 33 +++++++++++++++++++ EnvelopeGenerator.Web/Views/TFAReg/Reg.cshtml | 20 +++++------ 4 files changed, 109 insertions(+), 10 deletions(-) diff --git a/EnvelopeGenerator.Application/Resources/Resource.de-DE.resx b/EnvelopeGenerator.Application/Resources/Resource.de-DE.resx index b6914efa..fcdbfb8a 100644 --- a/EnvelopeGenerator.Application/Resources/Resource.de-DE.resx +++ b/EnvelopeGenerator.Application/Resources/Resource.de-DE.resx @@ -348,4 +348,37 @@ Öffnen + + 2FA Registrierung + + + Registrierung + + + Diese Seite ist bis {0} sichtbar. + + + Schritt 1 - Download einer 2FA Applikation + + + Bitte nehmen Sie Ihr Smartphone zur Hand und laden eine Applikation herunter, die zur Zwei-Faktor-Authentifizierung (2FA) benutzt werden kann. + + + Folgende Applikationen empfehlen wir + + + Schritt 2 - Scannen des QR-Codes + + + Sobald Sie eine Zwei-Faktor-Authentifizierung App installiert haben, können Sie fortfahren und innerhalb der Applikation die Option zum Scannen eines QR-Codes suchen und bestätigen. Im Anschluss, sobald die Kamera freigegeben wurde, können Sie den QR-Code von uns scannen. + + + Schritt 3 - Verifizierung des Codes + + + Sie können nun in der Zwei-Faktor-Authentifizierung App einen Zahlencode zur Verifizierung des Vorganges ablesen. Bitte tragen Sie diesen Code in das unten aufgeführte Eingabefeld ein und Klicken auf + + + Senden + \ No newline at end of file diff --git a/EnvelopeGenerator.Application/Resources/Resource.en-US.resx b/EnvelopeGenerator.Application/Resources/Resource.en-US.resx index 87098946..985b8794 100644 --- a/EnvelopeGenerator.Application/Resources/Resource.en-US.resx +++ b/EnvelopeGenerator.Application/Resources/Resource.en-US.resx @@ -348,4 +348,37 @@ Open + + 2FA Registration + + + Registration + + + This page is visible until {0}. + + + Step 1 – Download a 2FA application + + + Please take your smartphone and download an application that can be used for two-factor authentication (2FA). + + + We recommend the following applications + + + Step 2 – Scan the QR code + + + Once you have installed a two-factor authentication app, you can proceed and look for the option to scan a QR code within the application and confirm it. Then, once the camera is enabled, you can scan the QR code provided by us. + + + Step 3 – Verify the code + + + You can now read a numeric code in the two-factor authentication app to verify the process. Please enter this code in the input field below and click + + + Submit + \ No newline at end of file diff --git a/EnvelopeGenerator.Application/Resources/Resource.fr-FR.resx b/EnvelopeGenerator.Application/Resources/Resource.fr-FR.resx index d650684e..8e4dd9da 100644 --- a/EnvelopeGenerator.Application/Resources/Resource.fr-FR.resx +++ b/EnvelopeGenerator.Application/Resources/Resource.fr-FR.resx @@ -348,4 +348,37 @@ Ouvrir + + Enregistrement 2FA + + + Inscription + + + Cette page est visible jusqu'au {0}. + + + Étape 1 – Téléchargez une application 2FA + + + Veuillez prendre votre smartphone et télécharger une application pouvant être utilisée pour l’authentification à deux facteurs (2FA). + + + Nous recommandons les applications suivantes + + + Étape 2 – Scannez le code QR + + + Une fois que vous avez installé une application d’authentification à deux facteurs, vous pouvez continuer et chercher dans l’application l’option pour scanner un code QR et la confirmer. Ensuite, une fois la caméra activée, vous pourrez scanner le code QR fourni par nos soins. + + + Étape 3 – Vérification du code + + + Vous pouvez maintenant lire un code numérique dans l’application d’authentification à deux facteurs pour vérifier l’opération. Veuillez saisir ce code dans le champ ci-dessous et cliquer sur + + + Envoyer + \ No newline at end of file diff --git a/EnvelopeGenerator.Web/Views/TFAReg/Reg.cshtml b/EnvelopeGenerator.Web/Views/TFAReg/Reg.cshtml index fdd9ce7e..1995e873 100644 --- a/EnvelopeGenerator.Web/Views/TFAReg/Reg.cshtml +++ b/EnvelopeGenerator.Web/Views/TFAReg/Reg.cshtml @@ -1,6 +1,6 @@ @using System.Globalization @{ - ViewData["Title"] = "2FA Registrierung"; + ViewData["Title"] = @_localizer["TfaRegistration"]; var totpQR64 = ViewData["TotpQR64"] as string; var regDeadline = ViewData["RegDeadline"] is DateTime _dateTime ? _dateTime : throw new InvalidOperationException("RegDeadline is not added to view in Reg.cshtml view."); } @@ -13,23 +13,23 @@

2-Factor Authentication (2FA)

-

Registrierung

+

@_localizer["Registration"]

-

@string.Format("Diese Seite ist bis {0} sichtbar.", regDeadline.ToString("d. MMM, HH:mm", new CultureInfo("de-DE")))

+

@string.Format(@_localizer["PageVisibleUntil"], regDeadline.ToString("d. MMM, HH:mm", new CultureInfo("de-DE")))