From 580d5a4bcc2aaadc6d2b5e6cf610da0ad8173b35 Mon Sep 17 00:00:00 2001 From: Xavier Guimard Date: Wed, 9 Mar 2016 06:06:46 +0000 Subject: [PATCH] More translations in errors --- .../lib/Lemonldap/NG/Manager/Attributes.pm | 159 ++++++++++-------- .../Lemonldap/NG/Manager/Build/Attributes.pm | 42 ++--- .../site/static/languages/en.json | 11 ++ .../site/static/languages/fr.json | 11 ++ 4 files changed, 133 insertions(+), 90 deletions(-) diff --git a/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Attributes.pm b/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Attributes.pm index 0330d5bd5..615b97307 100644 --- a/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Attributes.pm +++ b/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Attributes.pm @@ -70,9 +70,9 @@ qr/^(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a- 'test' => qr/^.*$/ }, 'keyTextContainer' => { - 'keyMsgFail' => 'Bad key name', + 'keyMsgFail' => '__badKeyName__', 'keyTest' => qr/^\w[\w\.\-]*$/, - 'msgFail' => 'Empty value non accorded', + 'msgFail' => '__emptyValueNotAllowed__', 'test' => qr/./ }, 'lmAttrOrMacro' => { @@ -280,8 +280,9 @@ sub attributes { 'type' => 'catAndAppList' }, 'authChoiceModules' => { - 'keyTest' => qr/^(\d*)?[a-zA-Z0-9_]+$/, - 'select' => [ + 'keyMsgFail' => '__badChoiceKey__', + 'keyTest' => qr/^(\d*)?[a-zA-Z0-9_]+$/, + 'select' => [ [ { 'k' => 'Apache', @@ -619,8 +620,9 @@ sub attributes { 'type' => 'text' }, 'CAS_proxiedServices' => { - 'keyTest' => qr/^\w+$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__badCasProxyId__', + 'keyTest' => qr/^\w+$/, + 'type' => 'keyTextContainer' }, 'CAS_renew' => { 'type' => 'bool' @@ -739,11 +741,12 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'type' => 'text' }, 'dbiExportedVars' => { - 'default' => {}, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'default' => {}, + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'dbiPasswordMailCol' => { 'type' => 'text' @@ -766,10 +769,11 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'mail' => 'mail', 'uid' => 'uid' }, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'domain' => { 'default' => 'example.com', @@ -782,6 +786,7 @@ qr/^(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA- 'type' => 'text' }, 'exportedHeaders' => { + 'keyMsgFail' => '__badHostname__', 'keyTest' => qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0-9]*[a-zA-Z0-9]|[a-zA-Z])[.]?)$/, 'test' => { @@ -816,10 +821,11 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'default' => { 'UA' => 'HTTP_USER_AGENT' }, - 'keyTest' => qr/^!?[_a-zA-Z][a-zA-Z0-9_]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[_a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[_a-zA-Z][a-zA-Z0-9_]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[_a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'facebookAppId' => { 'type' => 'text' @@ -832,11 +838,12 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'type' => 'int' }, 'facebookExportedVars' => { - 'default' => {}, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'default' => {}, + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'failedLoginNumber' => { 'default' => 5, @@ -860,11 +867,12 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'type' => 'int' }, 'googleExportedVars' => { - 'default' => {}, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'default' => {}, + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'grantSessionRules' => { 'keyTest' => sub { @@ -1025,10 +1033,11 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'mail' => 'mail', 'uid' => 'uid' }, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'LDAPFilter' => { 'type' => 'text' @@ -1113,7 +1122,7 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- my $l = shift(); my @s = split( /[\s,]+/, $l, 0 ); foreach my $s (@s) { - return 0, qq[Bad ldap uri "$s"] + return 0, qq[__badLdapUri__: "$s"] unless $s =~ m[^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?::\d{1,5})?/?.*)$]o; } @@ -1155,6 +1164,7 @@ m[^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: 'default' => { 'default' => 'deny' }, + 'keyMsgFail' => '__badHostname__', 'keyTest' => qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0-9]*[a-zA-Z0-9]|[a-zA-Z])[.]?)$/, 'test' => { @@ -1208,9 +1218,10 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'type' => 'keyTextContainer' }, 'macros' => { - 'default' => {}, - 'keyTest' => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/, - 'test' => sub { + 'default' => {}, + 'keyMsgFail' => '__badMacroName__', + 'keyTest' => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/, + 'test' => sub { my ( $val, $conf ) = @_; my $s = ''; my (@cf) = ( @@ -1621,11 +1632,12 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'type' => 'int' }, 'openIdExportedVars' => { - 'default' => {}, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'default' => {}, + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'openIdIDPList' => { 'default' => '0;', @@ -1825,7 +1837,8 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'type' => 'portalskinbackground' }, 'portalSkinRules' => { - 'keyTest' => sub { + 'keyMsgFail' => '__badSkinRule__', + 'keyTest' => sub { my ( $val, $conf ) = @_; my $s = ''; my (@cf) = ( @@ -1856,6 +1869,7 @@ qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0- 'type' => 'text' }, 'post' => { + 'keyMsgFail' => '__badHostname__', 'keyTest' => qr/^(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-zA-Z0-9]*[a-zA-Z0-9]|[a-zA-Z])[.]?)$/, 'test' => sub { @@ -2009,18 +2023,20 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'type' => 'text' }, 'samlIDPMetaDataExportedAttributes' => { - 'default' => {}, - 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - 'msgFail' => '__badValue__', - 'test' => qr/\w/, - 'type' => 'samlAttributeContainer' + 'default' => {}, + 'keyMsgFail' => '__badMetadataName__', + 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, + 'msgFail' => '__badValue__', + 'test' => qr/\w/, + 'type' => 'samlAttributeContainer' }, 'samlIDPMetaDataNodes' => { 'type' => 'samlIDPMetaDataNodeContainer' }, 'samlIDPMetaDataOptions' => { - 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__badMetadataName__', + 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, + 'type' => 'keyTextContainer' }, 'samlIDPMetaDataOptionsAdaptSessionUtime' => { 'default' => 0, @@ -2304,18 +2320,20 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'type' => 'bool' }, 'samlSPMetaDataExportedAttributes' => { - 'default' => {}, - 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - 'msgFail' => '__badValue__', - 'test' => qr/\w/, - 'type' => 'samlAttributeContainer' + 'default' => {}, + 'keyMsgFail' => '__badMetadataName__', + 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, + 'msgFail' => '__badValue__', + 'test' => qr/\w/, + 'type' => 'samlAttributeContainer' }, 'samlSPMetaDataNodes' => { 'type' => 'samlSPMetaDataNodeContainer' }, 'samlSPMetaDataOptions' => { - 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__badMetadataName__', + 'keyTest' => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, + 'type' => 'keyTextContainer' }, 'samlSPMetaDataOptionsCheckSLOMessageSignature' => { 'default' => 0, @@ -2514,8 +2532,9 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'type' => 'pcre' }, 'sessionDataToRemember' => { - 'keyTest' => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/, - 'type' => 'keyTextContainer' + 'keyMsgFail' => '__invalidSessionData__', + 'keyTest' => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/, + 'type' => 'keyTextContainer' }, 'singleIP' => { 'default' => 0, @@ -2538,11 +2557,12 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'type' => 'int' }, 'slaveExportedVars' => { - 'default' => {}, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'default' => {}, + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'slaveHeaderContent' => { 'type' => 'text' @@ -2758,11 +2778,12 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.] 'type' => 'int' }, 'webIDExportedVars' => { - 'default' => {}, - 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - 'msgFail' => '__badValue__', - 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, - 'type' => 'keyTextContainer' + 'default' => {}, + 'keyMsgFail' => '__badVariableName__', + 'keyTest' => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, + 'msgFail' => '__badValue__', + 'test' => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, + 'type' => 'keyTextContainer' }, 'webIDWhitelist' => { 'type' => 'text' diff --git a/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Build/Attributes.pm b/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Build/Attributes.pm index d66be6617..7538dc1a5 100644 --- a/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Build/Attributes.pm +++ b/lemonldap-ng-manager/lib/Lemonldap/NG/Manager/Build/Attributes.pm @@ -103,9 +103,9 @@ sub types { }, keyTextContainer => { test => qr/./, - msgFail => 'Empty value non accorded', + msgFail => '__emptyValueNotAllowed__', keyTest => qr/^\w[\w\.\-]*$/, - keyMsgFail => 'Bad key name', + keyMsgFail => '__badKeyName__', }, subContainer => { keyTest => qr/\w/, @@ -405,7 +405,7 @@ sub attributes { type => 'keyTextContainer', help => 'portalcustom.html', keyTest => $perlExpr, - keyMsgFail => 'Bad skin rule', + keyMsgFail => '__badSkinRule__', test => qr/^\w+$/, msgFail => '__badValue__', }, @@ -656,7 +656,7 @@ sub attributes { type => 'keyTextContainer', help => 'exportedvars.html', keyTest => qr/^!?[_a-zA-Z][a-zA-Z0-9_]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[_a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => { 'UA' => 'HTTP_USER_AGENT' }, @@ -675,7 +675,7 @@ sub attributes { help => 'exportedvars.html#extend_variables_using_macros_and_groups', keyTest => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/, - keyMsgFail => 'Bad macro name', + keyMsgFail => '__badMacroName__', test => $perlExpr, default => {}, documentation => 'Macros', @@ -720,7 +720,7 @@ sub attributes { sessionDataToRemember => { type => 'keyTextContainer', keyTest => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/, - keyMsgFail => 'Invalid session data', + keyMsgFail => '__invalidSessionData__', }, # SAML issuer @@ -1350,7 +1350,7 @@ sub attributes { type => 'samlAttributeContainer', help => 'authsaml.html#exported_attributes', keyTest => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - keyMsgFail => 'Bad metadata name', + keyMsgFail => '__badMetadataName__', test => qr/\w/, msgFail => '__badValue__', default => {}, @@ -1361,7 +1361,7 @@ sub attributes { samlIDPMetaDataOptions => { type => 'keyTextContainer', keyTest => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - keyMsgFail => 'Bad metadata name', + keyMsgFail => '__badMetadataName__', }, samlIDPMetaDataOptionsNameIDFormat => { type => 'select', @@ -1467,7 +1467,7 @@ sub attributes { type => 'samlAttributeContainer', help => 'idpsaml.html#exported_attributes', keyTest => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - keyMsgFail => 'Bad metadata name', + keyMsgFail => '__badMetadataName__', test => qr/\w/, msgFail => '__badValue__', default => {}, @@ -1478,7 +1478,7 @@ sub attributes { samlSPMetaDataOptions => { type => 'keyTextContainer', keyTest => qr/^[a-zA-Z](?:[a-zA-Z0-9_\-\.]*\w)?$/, - keyMsgFail => 'Bad metadata name', + keyMsgFail => '__badMetadataName__', }, samlSPSSODescriptorAuthnRequestsSigned => { default => 1, @@ -1662,7 +1662,7 @@ sub attributes { demoExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => { cn => 'cn', mail => 'mail', uid => 'uid', }, @@ -1711,7 +1711,7 @@ sub attributes { ldapExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => { cn => 'cn', mail => 'mail', uid => 'uid', }, @@ -1730,7 +1730,7 @@ sub attributes { foreach my $s (@s) { $s =~ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?::\d{1,5})?/?.*)$}o - or return ( 0, "Bad ldap uri \"$s\"" ); + or return ( 0, "__badLdapUri__: \"$s\"" ); } return 1; }, @@ -1861,7 +1861,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: CAS_proxiedServices => { type => 'keyTextContainer', keyTest => qr/^\w+$/, - keyMsgFail => 'Bad CAS proxied service identifier', + keyMsgFail => '__badCasProxyId__', }, # Radius @@ -1905,7 +1905,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: openIdExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => {}, @@ -1922,7 +1922,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: googleExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => {}, @@ -1940,7 +1940,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: facebookExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => {}, @@ -1967,7 +1967,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: webIDExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => {}, @@ -1997,7 +1997,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: dbiExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => {}, @@ -2028,7 +2028,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: slaveExportedVars => { type => 'keyTextContainer', keyTest => qr/^!?[a-zA-Z][a-zA-Z0-9_-]*$/, - keyMsgFail => 'Bad variable name', + keyMsgFail => '__badVariableName__', test => qr/^[a-zA-Z][a-zA-Z0-9_:\-]*$/, msgFail => '__badValue__', default => {}, @@ -2051,7 +2051,7 @@ m{^(?:ldapi://[^/]*/?|\w[\w\-\.]*(?::\d{1,5})?|ldap(?:s|\+tls)?://\w[\w\-\.]*(?: authChoiceModules => { type => 'authChoiceContainer', keyTest => qr/^(\d*)?[a-zA-Z0-9_]+$/, - keyMsgFail => 'Bad choice key', + keyMsgFail => '__badChoiceKey__', test => sub { 1 }, select => [ [ diff --git a/lemonldap-ng-manager/site/static/languages/en.json b/lemonldap-ng-manager/site/static/languages/en.json index 6b5812159..7055f3219 100644 --- a/lemonldap-ng-manager/site/static/languages/en.json +++ b/lemonldap-ng-manager/site/static/languages/en.json @@ -55,19 +55,28 @@ "authParams": "Authentication parameters", "auto": "Automatic", "backtoportal": "Back to portal", +"badCasProxyId": "Bad CAS proxied service identifier", +"badChoiceKey": "Bad key name in Choice menu", "badCookieName": "Bad cookie name", "badCustomFuncName": "Bad custom function name", "badDomainName": "Bad domain name", "badEncoding": "Bad encoding", "badExpression": "Bad expression", +"badHeaderName": "Bad header name", "badHostname": "Bad hostname", +"badLdapUri": "Bad LDAP URI", +"badKeyName": "Bad key name", "badIPv4Address": "Bad IPv4 address", +"badMacroName": "Bad macro name", +"badMetadataName": "Bad metadata name", "badPemEncoding": "Bad PEM encoding", "badPerlPackageName": "Bad Perl package name", "badRegexp": "Bad regular expression", "badRequest": "Bad request", +"badSkinRule": "Bad skin rule", "badUrl": "Bad URL", "badValue": "Bad value", +"badVariableName": "Bad variable name", "blackList": "Black list", "browse": "Browse", "browserIdAuthnLevel": "Authentication level", @@ -169,6 +178,7 @@ "edit": "Edit", "editContent": "Edit content", "emptyConf": "Empty configuration", +"emptyValueNotAllowed": "Empty value not allowed", "enabled": "Enabled", "enterPassword": "Enter password (optional)", "error": "Error", @@ -208,6 +218,7 @@ "https": "HTTPS", "incompleteForm": "Required fields are missing", "index": "Index", +"invalidSessionData": "Invalid session data", "internalReference": "Internal reference", "ipAddr": "IP address", "ipAddresses": "IP addresses", diff --git a/lemonldap-ng-manager/site/static/languages/fr.json b/lemonldap-ng-manager/site/static/languages/fr.json index 8a4f17d6b..fd1ec2353 100644 --- a/lemonldap-ng-manager/site/static/languages/fr.json +++ b/lemonldap-ng-manager/site/static/languages/fr.json @@ -55,19 +55,28 @@ "authParams": "Paramètres d'authentification", "auto": "Automatique", "backtoportal": "Retour au portail", +"badCasProxyId": "Mauvais identifiant de service proxy CAS", +"badChoiceKey": "Mauvais nom de clef dans le menu Choice", "badCookieName": "Mauvais nom de cookie", "badCustomFuncName": "Mauvais nom de fonction personnalisée", "badDomainName": "Mauvais nom de domaine", "badEncoding": "Mauvais encodage", "badExpression": "Mauvaise expression", +"badHeaderName": "Mauvais nom d'en-tête", "badHostname": "Mauvais nom d'hôte", +"badLdapUri": "Mauvaise URI LDAP", +"badKeyName": "Mauvais nom de clef", "badIPv4Address": "Mauvaise adresse IPv4", +"badMacroName": "Mauvais nom de macro", +"badMetadataName": "Mauvais nom de métadonnée", "badPemEncoding": "Encodage PEM incorrect", "badPerlPackageName": "Mauvais nom de paquet Perl", "badRegexp": "Mauvaise expression rationnelle", "badRequest": "Mauvaise requête", +"badSkinRule": "Mauvaise règle", "badUrl": "Mauvaise URL", "badValue": "Mauvaise valeur", +"badVariableName": "Mauvais nom de variable", "blackList": "Liste noire", "browse": "Naviguer", "browserIdAuthnLevel": "Niveau d'authentification", @@ -169,6 +178,7 @@ "edit": "Éditer", "editContent": "Éditer le contenu", "emptyConf": "Configuration vide", +"emptyValueNotAllowed": "Valeur nulle non accordé", "enabled": "Activé", "enterPassword": "Entrer le mot de passe (optionnel)", "error": "Erreur", @@ -208,6 +218,7 @@ "https": "HTTPS", "incompleteForm": "Des champs requis manquent", "index": "Index", +"invalidSessionData": "Donnée de session invalide", "internalReference": "Référence interne ", "ipAddr": "Adresse IP", "ipAddresses": "Adresses IP",