From 1a0f706b30bcbec09daf3a427e72d24fc8bc587c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Dubois?= Date: Fri, 30 Jan 2026 13:51:48 +0100 Subject: [PATCH 1/3] feat(locales): i18n for group restrictions message --- .../oidc/locales/de/LC_MESSAGES/pas.plugins.oidc.po | 6 +++++- .../oidc/locales/en/LC_MESSAGES/pas.plugins.oidc.po | 6 +++++- .../oidc/locales/es/LC_MESSAGES/pas.plugins.oidc.po | 6 +++++- src/pas/plugins/oidc/locales/pas.plugins.oidc.pot | 8 ++++++-- src/pas/plugins/oidc/plugins.py | 3 ++- 5 files changed, 23 insertions(+), 6 deletions(-) diff --git a/src/pas/plugins/oidc/locales/de/LC_MESSAGES/pas.plugins.oidc.po b/src/pas/plugins/oidc/locales/de/LC_MESSAGES/pas.plugins.oidc.po index abc813e..a56426d 100644 --- a/src/pas/plugins/oidc/locales/de/LC_MESSAGES/pas.plugins.oidc.po +++ b/src/pas/plugins/oidc/locales/de/LC_MESSAGES/pas.plugins.oidc.po @@ -129,7 +129,7 @@ msgstr "" msgid "Scope" msgstr "" -#: pas/plugins/oidc/browser/view.py:64 +#: pas/plugins/oidc/browser/view.py:65 #: pas/plugins/oidc/services/oidc/oidc.py:107 msgid "There was an error during the login process. Please try again." msgstr "Beim Anmeldevorgang ist ein Fehler aufgetreten. Bitte versuche es erneut." @@ -186,6 +186,10 @@ msgstr "" msgid "Userinfo Endpoint Method" msgstr "" +#: pas/plugins/oidc/plugins.py:424 +msgid "You are not allowed to log in due to group restrictions." +msgstr "" + #: pas/plugins/oidc/configure.zcml:33 msgid "pas.plugins.oidc" msgstr "pas.plugins.oidc" diff --git a/src/pas/plugins/oidc/locales/en/LC_MESSAGES/pas.plugins.oidc.po b/src/pas/plugins/oidc/locales/en/LC_MESSAGES/pas.plugins.oidc.po index d60f73e..1e7c88e 100644 --- a/src/pas/plugins/oidc/locales/en/LC_MESSAGES/pas.plugins.oidc.po +++ b/src/pas/plugins/oidc/locales/en/LC_MESSAGES/pas.plugins.oidc.po @@ -126,7 +126,7 @@ msgstr "" msgid "Scope" msgstr "" -#: pas/plugins/oidc/browser/view.py:64 +#: pas/plugins/oidc/browser/view.py:65 #: pas/plugins/oidc/services/oidc/oidc.py:107 msgid "There was an error during the login process. Please try again." msgstr "" @@ -183,6 +183,10 @@ msgstr "" msgid "Userinfo Endpoint Method" msgstr "" +#: pas/plugins/oidc/plugins.py:424 +msgid "You are not allowed to log in due to group restrictions." +msgstr "" + #: pas/plugins/oidc/configure.zcml:33 msgid "pas.plugins.oidc" msgstr "" diff --git a/src/pas/plugins/oidc/locales/es/LC_MESSAGES/pas.plugins.oidc.po b/src/pas/plugins/oidc/locales/es/LC_MESSAGES/pas.plugins.oidc.po index de9ee85..83166fe 100644 --- a/src/pas/plugins/oidc/locales/es/LC_MESSAGES/pas.plugins.oidc.po +++ b/src/pas/plugins/oidc/locales/es/LC_MESSAGES/pas.plugins.oidc.po @@ -131,7 +131,7 @@ msgstr "Solo es necesario para el Oracle Authentication Manager" msgid "Scope" msgstr "Ámbito" -#: pas/plugins/oidc/browser/view.py:64 +#: pas/plugins/oidc/browser/view.py:65 #: pas/plugins/oidc/services/oidc/oidc.py:107 msgid "There was an error during the login process. Please try again." msgstr "Hubo un error durante el proceso de inicio de sesión. Inténtalo de nuevo." @@ -188,6 +188,10 @@ msgstr "Propiedad de información de usuario utilizada como userid, 'sub' por de msgid "Userinfo Endpoint Method" msgstr "" +#: pas/plugins/oidc/plugins.py:424 +msgid "You are not allowed to log in due to group restrictions." +msgstr "" + #: pas/plugins/oidc/configure.zcml:33 msgid "pas.plugins.oidc" msgstr "pas.plugins.oidc" diff --git a/src/pas/plugins/oidc/locales/pas.plugins.oidc.pot b/src/pas/plugins/oidc/locales/pas.plugins.oidc.pot index 39d1d9f..dc16af6 100644 --- a/src/pas/plugins/oidc/locales/pas.plugins.oidc.pot +++ b/src/pas/plugins/oidc/locales/pas.plugins.oidc.pot @@ -4,7 +4,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2025-06-28 18:33+0000\n" +"POT-Creation-Date: 2026-01-30 12:38+0000\n" "PO-Revision-Date: YEAR-MO-DA HO:MI +ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -133,7 +133,7 @@ msgstr "" msgid "Scope" msgstr "" -#: pas/plugins/oidc/browser/view.py:64 +#: pas/plugins/oidc/browser/view.py:65 #: pas/plugins/oidc/services/oidc/oidc.py:107 msgid "There was an error during the login process. Please try again." msgstr "" @@ -190,6 +190,10 @@ msgstr "" msgid "Userinfo Endpoint Method" msgstr "" +#: pas/plugins/oidc/plugins.py:424 +msgid "You are not allowed to log in due to group restrictions." +msgstr "" + #: pas/plugins/oidc/configure.zcml:33 msgid "pas.plugins.oidc" msgstr "" diff --git a/src/pas/plugins/oidc/plugins.py b/src/pas/plugins/oidc/plugins.py index 6682738..fa71d8c 100644 --- a/src/pas/plugins/oidc/plugins.py +++ b/src/pas/plugins/oidc/plugins.py @@ -6,6 +6,7 @@ from oic.oic.message import OpenIDSchema from oic.oic.message import RegistrationResponse from oic.utils.authn.client import CLIENT_AUTHN_METHOD +from pas.plugins.oidc import _ from pas.plugins.oidc import logger from plone.base.utils import safe_text from plone.protect.utils import safeWrite @@ -420,7 +421,7 @@ def rememberIdentity(self, userinfo): user = pas.getUserById(user_id) if not self.user_can_login(userinfo): - message = "You are not allowed to log in due to group restrictions." + message = _("You are not allowed to log in due to group restrictions.") api.portal.show_message(message=message, request=self.REQUEST, type="error") if user: raise AssertionError( From 4e3cdbbb2180fa2cd1c20ca9a16a5a556d962b0d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Dubois?= Date: Fri, 30 Jan 2026 13:52:37 +0100 Subject: [PATCH 2/3] feat(locales): french --- .../fr/LC_MESSAGES/pas.plugins.oidc.po | 196 ++++++++++++++++++ 1 file changed, 196 insertions(+) create mode 100644 src/pas/plugins/oidc/locales/fr/LC_MESSAGES/pas.plugins.oidc.po diff --git a/src/pas/plugins/oidc/locales/fr/LC_MESSAGES/pas.plugins.oidc.po b/src/pas/plugins/oidc/locales/fr/LC_MESSAGES/pas.plugins.oidc.po new file mode 100644 index 0000000..be2d09f --- /dev/null +++ b/src/pas/plugins/oidc/locales/fr/LC_MESSAGES/pas.plugins.oidc.po @@ -0,0 +1,196 @@ +msgid "" +msgstr "" +"Project-Id-Version: PACKAGE VERSION\n" +"POT-Creation-Date: YEAR-MO-DA HO:MI +ZONE\n" +"PO-Revision-Date: YEAR-MO-DA HO:MI +ZONE\n" +"Last-Translator: FULL NAME \n" +"Language-Team: LANGUAGE \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=utf-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=1; plural=0\n" +"Language-Code: fr\n" +"Language-Name: French\n" +"Preferred-Encodings: utf-8 latin1\n" +"Domain: DOMAIN\n" + +#: pas/plugins/oidc/www/oidcPluginForm.zpt:54 +msgid "Add" +msgstr "Ajouter" + +#: pas/plugins/oidc/interfaces.py:70 +msgid "Allowed Groups" +msgstr "Groupes autorisés" + +#: pas/plugins/oidc/interfaces.py:24 +msgid "Client ID" +msgstr "Client ID" + +#: pas/plugins/oidc/interfaces.py:30 +msgid "Client secret" +msgstr "Client secret" + +#: pas/plugins/oidc/interfaces.py:81 +msgid "Create authentication __ac ticket" +msgstr "Créer un ticket d'authentification __ac" + +#: pas/plugins/oidc/interfaces.py:87 +msgid "Create authentication auth_token (volto/restapi) ticket" +msgstr "Créer un ticket d'authentification auth_token (volto/restapi)" + +#: pas/plugins/oidc/interfaces.py:80 +msgid "Create authentication ticket" +msgstr "Créer un ticket d'authentification" + +#: pas/plugins/oidc/interfaces.py:58 +msgid "Create groups / update group memberships" +msgstr "Créer les groupes / mettre à jour les adhésions aux groupes" + +#: pas/plugins/oidc/interfaces.py:86 +msgid "Create restapi ticket" +msgstr "Créer un ticket restapi" + +#: pas/plugins/oidc/interfaces.py:52 +msgid "Create user / update user properties" +msgstr "Créer l'utilisateur / mettre à jour les propriétés de l'utilisateur" + +#: pas/plugins/oidc/interfaces.py:73 +msgid "Group" +msgstr "Groupe" + +#: pas/plugins/oidc/interfaces.py:141 +msgid "HTTP Method to use for the userinfo endpoint" +msgstr "Méthode HTTP à utiliser pour le endpoint userinfo" + +#: pas/plugins/oidc/www/oidcPluginForm.zpt:26 +msgid "Id" +msgstr "Id" + +#: pas/plugins/oidc/interfaces.py:133 +msgid "Identity Domain Name" +msgstr "" + +#: pas/plugins/oidc/configure.zcml:33 +msgid "Installs the pas.plugins.oidc add-on." +msgstr "Installe le module complémentaire pas.plugins.oidc." + +#: pas/plugins/oidc/interfaces.py:71 +msgid "List of groups that are allowed to log in." +msgstr "Liste des groupes autorisés à se connecter." + +#: pas/plugins/oidc/controlpanel/classic.py:168 +msgid "OIDC Plugin Settings" +msgstr "Paramètres du plugin OIDC" + +#: pas/plugins/oidc/www/oidcPluginForm.zpt:13 +msgid "OIDC Plugin manage the details of the OpenID Connect Authentication plugin Pluggable Auth Service functionality." +msgstr "Le plugin OIDC gère les détails de la fonctionnalité du plugin d'authentification OpenID Connect Pluggable Auth Service." + +#: pas/plugins/oidc/profiles/default/controlpanel.xml +msgid "OIDC Settings" +msgstr "Paramètres OIDC" + +#: pas/plugins/oidc/controlpanel/oidc.py:19 +msgid "OIDC settings" +msgstr "Paramètres OIDC" + +#: pas/plugins/oidc/interfaces.py:18 +msgid "OIDC/OAuth2 Issuer" +msgstr "Issuer OIDC/OAuth2" + +#: pas/plugins/oidc/interfaces.py:92 +msgid "Open ID scopes" +msgstr "Scopes Open ID" + +#: pas/plugins/oidc/interfaces.py:93 +msgid "Open ID scopes to request to the server" +msgstr "Scopes Open ID à demander au serveur" + +#: pas/plugins/oidc/interfaces.py:126 +msgid "Property used as userid" +msgstr "Propriété utilisée comme userid" + +#: pas/plugins/oidc/services/oidc/oidc.py:95 +msgid "Provider is not properly configured." +msgstr "Le fournisseur n'est pas correctement configuré." + +#: pas/plugins/oidc/interfaces.py:36 +msgid "Redirect uris" +msgstr "URIs de redirection" + +#: pas/plugins/oidc/interfaces.py:134 +msgid "Required for Oracle Authentication Manager only" +msgstr "Requis uniquement pour Oracle Authentication Manager" + +#: pas/plugins/oidc/interfaces.py:95 +msgid "Scope" +msgstr "Scope" + +#: pas/plugins/oidc/browser/view.py:65 +#: pas/plugins/oidc/services/oidc/oidc.py:107 +msgid "There was an error during the login process. Please try again." +msgstr "Une erreur s'est produite lors du processus de connexion. Veuillez réessayer." + +#: pas/plugins/oidc/browser/view.py:57 +msgid "There was an error getting the oauth2 client." +msgstr "Une erreur s'est produite lors de la récupération du client oauth2." + +#: pas/plugins/oidc/www/oidcPluginForm.zpt:40 +msgid "Title" +msgstr "Titre" + +#: pas/plugins/oidc/interfaces.py:39 +msgid "URI" +msgstr "URI" + +#: pas/plugins/oidc/configure.zcml:42 +msgid "Uninstalls the pas.plugins.oidc add-on." +msgstr "Désinstalle le module complémentaire pas.plugins.oidc." + +#: pas/plugins/oidc/interfaces.py:102 +msgid "Use PKCE" +msgstr "Utiliser PKCE" + +#: pas/plugins/oidc/interfaces.py:46 +msgid "Use Zope session data manager" +msgstr "Utiliser le gestionnaire de données de session Zope" + +#: pas/plugins/oidc/interfaces.py:117 +msgid "Use a modified OpenID Schema for email_verified and phone_number_verified boolean values coming as string" +msgstr "Utiliser un schéma OpenID modifié pour les valeurs booléennes email_verified et phone_number_verified provenant sous forme de chaîne" + +#: pas/plugins/oidc/interfaces.py:108 +msgid "Use deprecated redirect_uri" +msgstr "Utiliser redirect_uri obsolète" + +#: pas/plugins/oidc/interfaces.py:109 +msgid "Use deprecated redirect_uri for logout url(/Plone/acl_users/oidc/logout)" +msgstr "Utiliser redirect_uri obsolète pour l'URL de déconnexion (/Plone/acl_users/oidc/logout)" + +#: pas/plugins/oidc/interfaces.py:116 +msgid "Use modified OpenID Schema" +msgstr "Utiliser un schéma OpenID modifié" + +#: pas/plugins/oidc/interfaces.py:64 +msgid "User info property used as groupid, default 'groups'" +msgstr "Propriété des informations utilisateur utilisée comme groupid, par défaut 'groups'" + +#: pas/plugins/oidc/interfaces.py:127 +msgid "User info property used as userid, default 'sub'." +msgstr "Propriété des informations utilisateur utilisée comme userid, par défaut 'sub'." + +#: pas/plugins/oidc/interfaces.py:140 +msgid "Userinfo Endpoint Method" +msgstr "Méthode du endpoint Userinfo" + +#: pas/plugins/oidc/plugins.py:424 +msgid "You are not allowed to log in due to group restrictions." +msgstr "Vous n'êtes pas autorisé à vous connecter en raison de restrictions de groupe." + +#: pas/plugins/oidc/configure.zcml:33 +msgid "pas.plugins.oidc" +msgstr "pas.plugins.oidc" + +#: pas/plugins/oidc/configure.zcml:42 +msgid "pas.plugins.oidc (uninstall)" +msgstr "pas.plugins.oidc (désinstallation)" From 64e1a874973598bd423b64671a33f62e988bce41 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Dubois?= Date: Fri, 30 Jan 2026 14:02:07 +0100 Subject: [PATCH 3/3] doc: news fragment --- news/83.feature | 1 + 1 file changed, 1 insertion(+) create mode 100644 news/83.feature diff --git a/news/83.feature b/news/83.feature new file mode 100644 index 0000000..30d6757 --- /dev/null +++ b/news/83.feature @@ -0,0 +1 @@ +Add french translation. @remdub \ No newline at end of file