Commit 2112fb78 authored by Côme Bernigaud's avatar Côme Bernigaud Committed by Benoit Mortier
Browse files

Fixes #3757 Added an option to force password ask for SASL method

Showing with 21 additions and 4 deletions
+21 -4
...@@ -404,6 +404,12 @@ attributetype ( 1.3.6.1.4.1.38414.8.19.1 NAME 'fdOGroupRDN' ...@@ -404,6 +404,12 @@ attributetype ( 1.3.6.1.4.1.38414.8.19.1 NAME 'fdOGroupRDN'
SYNTAX 1.3.6.1.4.1.1466.115.121.1.26 SYNTAX 1.3.6.1.4.1.1466.115.121.1.26
SINGLE-VALUE) SINGLE-VALUE)
attributetype ( 1.3.6.1.4.1.38414.8.19.2 NAME 'fdForceSaslPasswordAsk'
DESC 'FusionDirectory - Force password ask for SASL users'
EQUALITY booleanMatch
SYNTAX 1.3.6.1.4.1.1466.115.121.1.7
SINGLE-VALUE )
# merged from dashboard-fd.schema - Needed by Fusion Directory for dashboard options # merged from dashboard-fd.schema - Needed by Fusion Directory for dashboard options
attributetype ( 1.3.6.1.4.1.38414.27.1.1 NAME 'fdDashboardPrefix' attributetype ( 1.3.6.1.4.1.38414.27.1.1 NAME 'fdDashboardPrefix'
...@@ -514,7 +520,7 @@ objectclass ( 1.3.6.1.4.1.38414.8.2.2 NAME 'fusionDirectoryPluginsConf' ...@@ -514,7 +520,7 @@ objectclass ( 1.3.6.1.4.1.38414.8.2.2 NAME 'fusionDirectoryPluginsConf'
DESC 'FusionDirectory plugins configuration' DESC 'FusionDirectory plugins configuration'
SUP top AUXILIARY SUP top AUXILIARY
MUST ( cn ) MUST ( cn )
MAY ( fdOGroupRDN ) ) MAY ( fdOGroupRDN $ fdForceSaslPasswordAsk ) )
objectclass ( 1.3.6.1.4.1.38414.8.2.3 NAME 'fdPasswordRecoveryConf' objectclass ( 1.3.6.1.4.1.38414.8.2.3 NAME 'fdPasswordRecoveryConf'
DESC 'FusionDirectory password recovery configuration' DESC 'FusionDirectory password recovery configuration'
......
...@@ -103,7 +103,8 @@ class passwordMethodsasl extends passwordMethod { ...@@ -103,7 +103,8 @@ class passwordMethodsasl extends passwordMethod {
*/ */
function need_password() function need_password()
{ {
return FALSE; global $config;
return ($config->get_cfg_value('forceSaslPasswordAsk', 'FALSE') == 'TRUE');
} }
} }
?> ?>
...@@ -38,8 +38,8 @@ class mainPluginsConfig extends simplePlugin ...@@ -38,8 +38,8 @@ class mainPluginsConfig extends simplePlugin
static function getAttributesInfo () static function getAttributesInfo ()
{ {
return array( return array(
'main' => array( 'ogroups' => array(
'name' => _('LDAP tree'), 'name' => _('Object groups'),
'attrs' => array( 'attrs' => array(
new StringAttribute ( new StringAttribute (
_('OGroup RDN'), _('Branch in which object groups will be stored'), _('OGroup RDN'), _('Branch in which object groups will be stored'),
...@@ -48,6 +48,16 @@ class mainPluginsConfig extends simplePlugin ...@@ -48,6 +48,16 @@ class mainPluginsConfig extends simplePlugin
), ),
) )
), ),
'sasl' => array(
'name' => _('SASL'),
'attrs' => array(
new BooleanAttribute (
_('Force Password asking'), _('Useful if you add a hook using password value when SASL user passwords are edited'),
'fdForceSaslPasswordAsk', TRUE,
FALSE
),
)
),
); );
} }
......
  • bmortier @bmortier

    mentioned in issue #1241

    By fwe on 2017-09-02T15:19:06 (imported from GitLab)

    ·

    mentioned in issue #1241

    By fwe on 2017-09-02T15:19:06 (imported from GitLab)

    Toggle commit list
Supports Markdown
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