This question about Configuration, Using an extension, LDAP: Answered

USERINFO not retrieving email

Our installation(s) of Foswiki work correctly with LdapContrib, LdapNgPlugin, and NewUserPlugin for everything except the USERINFO macro.

For example, the following correctly displays all LDAP users with their correct email address, etc.
  format="| $index | $wikiName | $loginName | $displayName | $emails |" 
  clear="$wikiName, $loginName, $displayName, $emails" 

However, the following displays the email address as "0" for all LDAP users.
%USERINFO{format="| $wikiname | $username | $emails |"}%

Any suggestions would be greatly appreciated.

-- DevinBougie - 24 Apr 2013

The problem was that the config needs PasswordManager set, even if registrations are disabled.

$Foswiki::cfg{PasswordManager} = 'Foswiki::Users::LdapPasswdUser';

"LdapUserMapping::getEmails" delegates to the password manager, so it has to be set. Without it set, the password manager base class gets called, which does

sub getEmails {
   ASSERT( 0, "should never be called" ) if DEBUG;

-- DevinBougie - 26 Apr 2013


QuestionForm edit

Subject Configuration, Using an extension, LDAP
Extension LdapContrib
Version Foswiki 1.1.8
Status Answered
Related Topics
Topic revision: r3 - 26 Apr 2013, DevinBougie
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy