Commit fc152768 authored by Xavier Guimard's avatar Xavier Guimard

Remove loca-only parameters (#1160)

parent 21f59356
......@@ -23,7 +23,7 @@ use constant HANDLERSECTION => "handler";
use constant MANAGERSECTION => "manager";
use constant SESSIONSEXPLORERSECTION => "sessionsExplorer";
use constant APPLYSECTION => "apply";
our $hashParameters = qr/^(?:(?:l(?:o(?:ca(?:lSessionStorageOption|tionRule)|goutService)|dapExportedVar|wpSslOpt)|(?:(?:d(?:emo|bi)|facebook|webID)ExportedVa|exported(?:Heade|Va))r|g(?:r(?:antSessionRule|oup)|lobalStorageOption)|c(?:as(?:StorageOption|Attribute)|ombModule)|re(?:moteGlobalStorageOption|loadUrl)|notificationStorageOption|CAS_proxiedService|macro)s|o(?:idc(?:RPMetaData(?:(?:Option(?:sExtraClaim)?|ExportedVar)s|Node)|OPMetaData(?:(?:ExportedVar|Option)s|J(?:SON|WKS)|Node)|S(?:erviceMetaDataAuthnContext|torageOptions))|penIdExportedVars)|s(?:aml(?:S(?:PMetaData(?:(?:ExportedAttribute|Option)s|Node|XML)|torageOptions)|IDPMetaData(?:(?:ExportedAttribute|Option)s|Node|XML))|essionDataToRemember|laveExportedVars)|p(?:ersistentStorageOptions|o(?:rtalSkinRules|st))|a(?:uthChoiceModules|pplicationList)|v(?:hostOptions|irtualHost))$/;
our $hashParameters = qr/^(?:(?:l(?:o(?:ca(?:lSessionStorageOption|tionRule)|goutService)|dapExportedVar|wpSslOpt)|(?:(?:d(?:emo|bi)|facebook|webID)ExportedVa|exported(?:Heade|Va))r|g(?:r(?:antSessionRule|oup)|lobalStorageOption)|n(?:otificationStorageOption|ginxCustomHandler)|c(?:as(?:StorageOption|Attribute)|ombModule)|re(?:moteGlobalStorageOption|loadUrl)|CAS_proxiedService|macro)s|o(?:idc(?:RPMetaData(?:(?:Option(?:sExtraClaim)?|ExportedVar)s|Node)|OPMetaData(?:(?:ExportedVar|Option)s|J(?:SON|WKS)|Node)|S(?:erviceMetaDataAuthnContext|torageOptions))|penIdExportedVars)|s(?:aml(?:S(?:PMetaData(?:(?:ExportedAttribute|Option)s|Node|XML)|torageOptions)|IDPMetaData(?:(?:ExportedAttribute|Option)s|Node|XML))|essionDataToRemember|laveExportedVars)|p(?:ersistentStorageOptions|o(?:rtalSkinRules|st))|a(?:uthChoiceModules|pplicationList)|v(?:hostOptions|irtualHost))$/;
our @sessionTypes = ( 'remoteGlobal', 'cas', 'global', 'localSession', 'persistent', 'saml', 'oidc' );
......
......@@ -20,7 +20,7 @@ our $specialNodeHash = {
};
our $doubleHashKeys = 'issuerDBGetParameters';
our $simpleHashKeys = '(?:(?:l(?:o(?:calSessionStorageOption|goutService)|dapExportedVar|wpSslOpt)|(?:(?:d(?:emo|bi)|facebook|webID)E|e)xportedVar|g(?:r(?:antSessionRule|oup)|lobalStorageOption)|c(?:as(?:StorageOption|Attribute)|ombModule)|p(?:ersistentStorageOption|ortalSkinRule)|re(?:moteGlobalStorageOption|loadUrl)|notificationStorageOption|CAS_proxiedService|macro)s|o(?:idcS(?:erviceMetaDataAuthnContext|torageOptions)|penIdExportedVars)|s(?:(?:amlStorageOption|laveExportedVar)s|essionDataToRemember)|a(?:uthChoiceModules|pplicationList))';
our $simpleHashKeys = '(?:(?:l(?:o(?:calSessionStorageOption|goutService)|dapExportedVar|wpSslOpt)|(?:(?:d(?:emo|bi)|facebook|webID)E|e)xportedVar|g(?:r(?:antSessionRule|oup)|lobalStorageOption)|n(?:otificationStorageOption|ginxCustomHandler)|c(?:as(?:StorageOption|Attribute)|ombModule)|p(?:ersistentStorageOption|ortalSkinRule)|re(?:moteGlobalStorageOption|loadUrl)|CAS_proxiedService|macro)s|o(?:idcS(?:erviceMetaDataAuthnContext|torageOptions)|penIdExportedVars)|s(?:(?:amlStorageOption|laveExportedVar)s|essionDataToRemember)|a(?:uthChoiceModules|pplicationList))';
our $specialNodeKeys = '(?:(?:saml(?:ID|S)|oidc[OR])PMetaDataNode|virtualHost)s';
our $oidcOPMetaDataNodeKeys = 'oidcOPMetaData(?:Options(?:C(?:lient(?:Secret|ID)|heckJWTSignature|onfigurationURI)|TokenEndpointAuthMethod|(?:JWKSTimeou|Promp)t|I(?:DTokenMaxAge|con)|S(?:toreIDToken|cope)|U(?:iLocales|seNonce)|Display(?:Name)?|AcrValues|MaxAge)|ExportedVars|J(?:SON|WKS))';
our $oidcRPMetaDataNodeKeys = 'oidcRPMetaData(?:Options(?:I(?:DToken(?:Expiration|SignAlg)|con)|(?:RedirectUri|ExtraClaim)s|AccessTokenExpiration|Client(?:Secret|ID)|BypassConsent|DisplayName|UserIDAttr)|ExportedVars)';
......
......@@ -32,8 +32,8 @@ sub init {
$args ||= {};
if ( my $localconf = $self->confAcc->getLocalConf(MANAGERSECTION) ) {
$self->{$_} = $args->{$_} // $localconf->{$_}
foreach ( keys %$localconf );
$self->{$_} = $args->{$_} //= $localconf->{$_}
foreach ( grep {$_ !~ /^(?:l|userL)ogger$/} keys %$localconf );
}
# Manager needs to keep new Ajax behaviour
......
......@@ -2665,30 +2665,6 @@ qr/(?:(?:https?):\/\/(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.]
],
'type' => 'select'
},
'secureTokenAllowOnError' => {
'default' => 1,
'type' => 'bool'
},
'secureTokenAttribute' => {
'default' => 'uid',
'type' => 'text'
},
'secureTokenExpiration' => {
'default' => 60,
'type' => 'int'
},
'secureTokenHeader' => {
'default' => 'Auth-Token',
'type' => 'text'
},
'secureTokenMemcachedServers' => {
'default' => '127.0.0.1:11211',
'type' => 'text'
},
'secureTokenUrls' => {
'default' => '.*',
'type' => 'pcre'
},
'sessionDataToRemember' => {
'keyMsgFail' => '__invalidSessionData__',
'keyTest' => qr/^[_a-zA-Z][a-zA-Z0-9_]*$/,
......@@ -2943,40 +2919,6 @@ qr/^(?:(?:(?:(?:(?:(?:[a-zA-Z0-9][-a-zA-Z0-9]*)?[a-zA-Z0-9])[.])*(?:[a-zA-Z][-a-
},
'yubikeySecretKey' => {
'type' => 'text'
},
'zimbraAccountKey' => {
'type' => 'text'
},
'zimbraBy' => {
'default' => '',
'select' => [
{
'k' => '',
'v' => ''
},
{
'k' => 'name',
'v' => 'User name'
},
{
'k' => 'id',
'v' => 'User id'
},
{
'k' => 'foreignPrincipal',
'v' => 'Foreign principal'
}
],
'type' => 'select'
},
'zimbraPreAuthKey' => {
'type' => 'text'
},
'zimbraSsoUrl' => {
'type' => 'text'
},
'zimbraUrl' => {
'type' => 'text'
}
};
}
......
......@@ -577,13 +577,6 @@
"saveReport": "Save report",
"savingConfirmation": "Saving confirmation",
"securedCookie": "Secured Cookie (SSL)",
"secureTokenAllowOnError": "Allow requests in error",
"secureTokenAttribute": "Attribute to store",
"secureTokenExpiration": "Token expiration",
"secureTokenHandler": "Secure Token",
"secureTokenHeader": "Header name",
"secureTokenMemcachedServers": "Memcached servers",
"secureTokenUrls": "Protected URLs",
"security": "Security",
"serverError": "Server error",
"session": "session",
......@@ -614,7 +607,6 @@
"SMTPServer": "SMTP server",
"soapConfigServer": "SOAP configuration server",
"soapSessionServer": "SOAP session server",
"specialHandlers": "Special Handlers",
"specialRule": "Special rule",
"SSLAuthnLevel": "Authentication level",
"sslParams": "SSL parameters",
......@@ -693,12 +685,6 @@
"yubikeyPublicIDSize": "OTP public ID part size",
"yubikeySecretKey": "API secret key",
"zeroConfExplanations": "Server has no configuration. Use template to save the first.",
"zimbraAccountKey": "Account session key",
"zimbraBy": "Account type",
"zimbraHandler": "Zimbra",
"zimbraPreAuthKey": "Preauthentication key",
"zimbraSsoUrl": "Local SSO URL pattern",
"zimbraUrl": "Preauthentication URL",
"saml": "SAML",
"samlAttribute": "SAML attribute",
......
......@@ -577,13 +577,6 @@
"saveReport": "Rapport de sauvegarde",
"savingConfirmation": "Confirmation de sauvegarde",
"securedCookie": "Cookie sécurisé (HTTPS)",
"secureTokenAllowOnError": "Autoriser les requêtes en erreur",
"secureTokenAttribute": "Attribut à stocker",
"secureTokenExpiration": "Expiration du jeton",
"secureTokenHandler": "Jeton sécurisé",
"secureTokenHeader": "Nom de l'en-tête HTTP",
"secureTokenMemcachedServers": "Serveurs Memcached",
"secureTokenUrls": "URLs protégées",
"security": "Sécurité",
"serverError": "Erreur du serveur",
"session": "session",
......@@ -614,7 +607,6 @@
"SMTPServer": "Serveur SMTP",
"soapConfigServer": "Serveur de configurations SOAP",
"soapSessionServer": "Serveur de sessions SOAP",
"specialHandlers": "Handlers spéciaux",
"specialRule": "Règle spécifique",
"SSLAuthnLevel": "Niveau d'authentification",
"sslParams": "Paramètres SSL",
......@@ -693,12 +685,6 @@
"yubikeyPublicIDSize": "Taille de la partie publique de l'OTP",
"yubikeySecretKey": "Clef secrète de l'API",
"zeroConfExplanations": "Le serveur ne dispose pas de configuration. Cette configuration de base vous permet d'en initialiser une.",
"zimbraAccountKey": "Clef de session pour le compte",
"zimbraBy": "Type de compte",
"zimbraHandler": "Zimbra",
"zimbraPreAuthKey": "Clef de préauthentication",
"zimbraSsoUrl": "Motif pour l'URL de SSO locale ",
"zimbraUrl": "URL de préauthentification",
"saml": "SAML",
"samlAttribute": "Attribut SAML",
......
......@@ -1459,87 +1459,6 @@
"id": "portalRedirection",
"title": "portalRedirection",
"type": "simpleInputContainer"
}, {
"_nodes": [{
"_nodes": [{
"id": "zimbraPreAuthKey",
"title": "zimbraPreAuthKey"
}, {
"id": "zimbraAccountKey",
"title": "zimbraAccountKey"
}, {
"default": "",
"id": "zimbraBy",
"select": [{
"k": "",
"v": ""
}, {
"k": "name",
"v": "User name"
}, {
"k": "id",
"v": "User id"
}, {
"k": "foreignPrincipal",
"v": "Foreign principal"
}],
"title": "zimbraBy",
"type": "select"
}, {
"id": "zimbraUrl",
"title": "zimbraUrl"
}, {
"id": "zimbraSsoUrl",
"title": "zimbraSsoUrl"
}],
"id": "zimbraHandler",
"title": "zimbraHandler",
"type": "simpleInputContainer"
}, {
"_nodes": [{
"id": "sympaSecret",
"title": "sympaSecret"
}, {
"id": "sympaMailKey",
"title": "sympaMailKey"
}],
"id": "sympaHandler",
"title": "sympaHandler",
"type": "simpleInputContainer"
}, {
"_nodes": [{
"default": "127.0.0.1:11211",
"id": "secureTokenMemcachedServers",
"title": "secureTokenMemcachedServers"
}, {
"default": 60,
"id": "secureTokenExpiration",
"title": "secureTokenExpiration",
"type": "int"
}, {
"default": "uid",
"id": "secureTokenAttribute",
"title": "secureTokenAttribute"
}, {
"default": ".*",
"id": "secureTokenUrls",
"title": "secureTokenUrls"
}, {
"default": "Auth-Token",
"id": "secureTokenHeader",
"title": "secureTokenHeader"
}, {
"default": 1,
"id": "secureTokenAllowOnError",
"title": "secureTokenAllowOnError",
"type": "bool"
}],
"id": "secureTokenHandler",
"title": "secureTokenHandler",
"type": "simpleInputContainer"
}],
"id": "specialHandlers",
"title": "specialHandlers"
}, {
"cnodes": "logoutServices",
"default": [],
......
......@@ -1637,94 +1637,6 @@
"type": "boolOrExpr",
"data": 0
}]
}, {
"id": "specialHandlers",
"title": "specialHandlers",
"nodes": [{
"id": "zimbraHandler",
"title": "zimbraHandler",
"type": "simpleInputContainer",
"nodes": [{
"id": "zimbraPreAuthKey",
"title": "zimbraPreAuthKey"
}, {
"id": "zimbraAccountKey",
"title": "zimbraAccountKey"
}, {
"default": "",
"id": "zimbraBy",
"select": [{
"k": "",
"v": ""
}, {
"k": "name",
"v": "User name"
}, {
"k": "id",
"v": "User id"
}, {
"k": "foreignPrincipal",
"v": "Foreign principal"
}],
"title": "zimbraBy",
"type": "select",
"data": ""
}, {
"id": "zimbraUrl",
"title": "zimbraUrl"
}, {
"id": "zimbraSsoUrl",
"title": "zimbraSsoUrl"
}]
}, {
"id": "sympaHandler",
"title": "sympaHandler",
"type": "simpleInputContainer",
"nodes": [{
"id": "sympaSecret",
"title": "sympaSecret"
}, {
"id": "sympaMailKey",
"title": "sympaMailKey"
}]
}, {
"id": "secureTokenHandler",
"title": "secureTokenHandler",
"type": "simpleInputContainer",
"nodes": [{
"default": "127.0.0.1:11211",
"id": "secureTokenMemcachedServers",
"title": "secureTokenMemcachedServers",
"data": "127.0.0.1:11211"
}, {
"default": 60,
"id": "secureTokenExpiration",
"title": "secureTokenExpiration",
"type": "int",
"data": 60
}, {
"default": "uid",
"id": "secureTokenAttribute",
"title": "secureTokenAttribute",
"data": "uid"
}, {
"default": ".*",
"id": "secureTokenUrls",
"title": "secureTokenUrls",
"data": ".*"
}, {
"default": "Auth-Token",
"id": "secureTokenHeader",
"title": "secureTokenHeader",
"data": "Auth-Token"
}, {
"default": 1,
"id": "secureTokenAllowOnError",
"title": "secureTokenAllowOnError",
"type": "bool",
"data": 1
}]
}]
}, {
"default": [],
"id": "logoutServices",
......
......@@ -1648,94 +1648,6 @@
"type": "boolOrExpr",
"data": 0
}]
}, {
"id": "specialHandlers",
"title": "specialHandlers",
"nodes": [{
"id": "zimbraHandler",
"title": "zimbraHandler",
"type": "simpleInputContainer",
"nodes": [{
"id": "zimbraPreAuthKey",
"title": "zimbraPreAuthKey"
}, {
"id": "zimbraAccountKey",
"title": "zimbraAccountKey"
}, {
"default": "",
"id": "zimbraBy",
"select": [{
"k": "",
"v": ""
}, {
"k": "name",
"v": "User name"
}, {
"k": "id",
"v": "User id"
}, {
"k": "foreignPrincipal",
"v": "Foreign principal"
}],
"title": "zimbraBy",
"type": "select",
"data": ""
}, {
"id": "zimbraUrl",
"title": "zimbraUrl"
}, {
"id": "zimbraSsoUrl",
"title": "zimbraSsoUrl"
}]
}, {
"id": "sympaHandler",
"title": "sympaHandler",
"type": "simpleInputContainer",
"nodes": [{
"id": "sympaSecret",
"title": "sympaSecret"
}, {
"id": "sympaMailKey",
"title": "sympaMailKey"
}]
}, {
"id": "secureTokenHandler",
"title": "secureTokenHandler",
"type": "simpleInputContainer",
"nodes": [{
"default": "127.0.0.1:11211",
"id": "secureTokenMemcachedServers",
"title": "secureTokenMemcachedServers",
"data": "127.0.0.1:11211"
}, {
"default": 60,
"id": "secureTokenExpiration",
"title": "secureTokenExpiration",
"type": "int",
"data": 60
}, {
"default": "uid",
"id": "secureTokenAttribute",
"title": "secureTokenAttribute",
"data": "uid"
}, {
"default": ".*",
"id": "secureTokenUrls",
"title": "secureTokenUrls",
"data": ".*"
}, {
"default": "Auth-Token",
"id": "secureTokenHeader",
"title": "secureTokenHeader",
"data": "Auth-Token"
}, {
"default": 1,
"id": "secureTokenAllowOnError",
"title": "secureTokenAllowOnError",
"type": "bool",
"data": 1
}]
}]
}, {
"default": [],
"id": "logoutServices",
......
......@@ -1637,94 +1637,6 @@
"type": "boolOrExpr",
"data": 0
}]
}, {
"id": "specialHandlers",
"title": "specialHandlers",
"nodes": [{
"id": "zimbraHandler",
"title": "zimbraHandler",
"type": "simpleInputContainer",
"nodes": [{
"id": "zimbraPreAuthKey",
"title": "zimbraPreAuthKey"
}, {
"id": "zimbraAccountKey",
"title": "zimbraAccountKey"
}, {
"default": "",
"id": "zimbraBy",
"select": [{
"k": "",
"v": ""
}, {
"k": "name",
"v": "User name"
}, {
"k": "id",
"v": "User id"
}, {
"k": "foreignPrincipal",
"v": "Foreign principal"
}],
"title": "zimbraBy",
"type": "select",
"data": ""
}, {
"id": "zimbraUrl",
"title": "zimbraUrl"
}, {
"id": "zimbraSsoUrl",
"title": "zimbraSsoUrl"
}]
}, {
"id": "sympaHandler",
"title": "sympaHandler",
"type": "simpleInputContainer",
"nodes": [{
"id": "sympaSecret",
"title": "sympaSecret"
}, {
"id": "sympaMailKey",
"title": "sympaMailKey"
}]
}, {
"id": "secureTokenHandler",
"title": "secureTokenHandler",
"type": "simpleInputContainer",
"nodes": [{
"default": "127.0.0.1:11211",
"id": "secureTokenMemcachedServers",
"title": "secureTokenMemcachedServers",
"data": "127.0.0.1:11211"
}, {
"default": 60,
"id": "secureTokenExpiration",
"title": "secureTokenExpiration",
"type": "int",
"data": 60
}, {
"default": "uid",
"id": "secureTokenAttribute",
"title": "secureTokenAttribute",
"data": "uid"
}, {
"default": ".*",
"id": "secureTokenUrls",
"title": "secureTokenUrls",
"data": ".*"
}, {
"default": "Auth-Token",
"id": "secureTokenHeader",
"title": "secureTokenHeader",
"data": "Auth-Token"
}, {
"default": 1,
"id": "secureTokenAllowOnError",
"title": "secureTokenAllowOnError",
"type": "bool",
"data": 1
}]
}]
}, {
"default": [],
"id": "logoutServices",
......
......@@ -2306,106 +2306,6 @@
"title": "portalRedirection",
"type": "simpleInputContainer"
},
{
"_nodes": [{
"_nodes": [{
"id": "zimbraPreAuthKey",
"title": "zimbraPreAuthKey"
},
{
"id": "zimbraAccountKey",
"title": "zimbraAccountKey"
},
{
"default": "",
"id": "zimbraBy",
"select": [{
"k": "",
"v": ""
},
{
"k": "name",
"v": "User name"
},
{
"k": "id",
"v": "User id"
},
{
"k": "foreignPrincipal",
"v": "Foreign principal"
}],
"title": "zimbraBy",
"type": "select"
},
{
"id": "zimbraUrl",
"title": "zimbraUrl"
},
{
"id": "zimbraSsoUrl",
"title": "zimbraSsoUrl"
}],
"help": "applications/zimbra.html",
"id": "zimbraHandler",
"title": "zimbraHandler",
"type": "simpleInputContainer"
},
{
"_nodes": [{
"id": "sympaSecret",
"title": "sympaSecret"
},
{
"id": "sympaMailKey",
"title": "sympaMailKey"
}],
"help": "applications/sympa.html",
"id": "sympaHandler",
"title": "sympaHandler",
"type": "simpleInputContainer"
},
{
"_nodes": [{
"default": "127.0.0.1:11211",
"id": "secureTokenMemcachedServers",
"title": "secureTokenMemcachedServers"
},
{
"default": 60,
"id": "secureTokenExpiration",
"title": "secureTokenExpiration",
"type": "int"
},
{
"default": "uid",
"id": "secureTokenAttribute",
"title": "secureTokenAttribute"
},
{
"default": ".*",
"id": "secureTokenUrls",
"title": "secureTokenUrls"
},
{
"default": "Auth-Token",
"id": "secureTokenHeader",
"title": "secureTokenHeader"
},
{
"default": 1,
"id": "secureTokenAllowOnError",
"title": "secureTokenAllowOnError",
"type": "bool"
}],
"help": "securetoken.html",
"id": "secureTokenHandler",
"title": "secureTokenHandler",
"type": "simpleInputContainer"
}],
"id": "specialHandlers",
"title": "specialHandlers"
},
{
"cnodes": "nginxCustomHandlers",
"id": "nginxCustomHandlers",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment