SID-00888: wikiname is Main.uid
| Status: |
Answered |
TWiki version: |
5.0.0 |
Perl version: |
v5.10.1 |
| Category: |
LdapContrib |
Server OS: |
Ubuntu 10.4, 2.6.32-23-server |
Last update: |
15 years ago |
I'm running Twiki-5.0
If I login, my uid being "dgroomba", I authenticate succesfully. However, my wikiname appears as "Main.dgroomba". I would expect it to appear as "DavidGroomba", instead.
So, If I look at the changes made to the wiki, logged in as myself, I see Main.dgroomba as the author of changes.
However, logging in as another user and listing the changes, I instead see
DavidGroomba as the author. However, that user now logged in shows all their changes as Main.uid.
I see in the doc that it reads:
NormalizeLoginNames on:
"However the normalized result will not be forced to be a cammel case
WikiName. "
Is there a way to force this? So my wikiname becomes
DavidGroomba upon authenticating against ldap?
My pertinent configs listed below:
$TWiki::cfg{Ldap}{LoginFilter} = 'objectClass=posixAccount';
$TWiki::cfg{Ldap}{LoginAttribute} = 'uid';
$TWiki::cfg{Ldap}{WikiNameAttribute} = 'cn';
$TWiki::cfg{Ldap}{NormalizeWikiNames} = 1;
$TWiki::cfg{Ldap}{NormalizeLoginNames} = 1;
$TWiki::cfg{Ldap}{WikiNameAliases} = '';
$TWiki::cfg{Ldap}{AllowChangePassword} = 0;
$TWiki::cfg{Ldap}{SecondaryPasswordManager} = 'none';
$TWiki::cfg{Ldap}{GroupBase} = 'ou=groups,dc=example,dc=com';
$TWiki::cfg{Ldap}{GroupFilter} = 'objectClass=posixGroup';
$TWiki::cfg{Ldap}{GroupAttribute} = 'cn';
$TWiki::cfg{Ldap}{MemberAttribute} = 'memberUid';
$TWiki::cfg{Ldap}{MemberIndirection} = 0;
$TWiki::cfg{Ldap}{TWikiGroupsBackoff} = 1;
$TWiki::cfg{Ldap}{NormalizeGroupNames} = 1;
I see this question already exists in support, but was closed prior to resolution. My apologies for asking again.
--
DaveGroomba - 2010-07-07
Discussion and Answer
What
{UserMappingManager} do you use? If you use
TWiki::Users::TWikiUserMapping you can fix the mapping from your login name to your
WikiName in your Main.TWikiUsers topic.
--
PeterThoeny - 2010-07-07
Thanks for the hasty reply!
I'm using TWiki::Users::LdapUserMapping -- I thought that was required for the values (
U2W, etc.) to be used from the cache.db beiing generated by
LdapContrib.
--
DaveGroomba - 2010-07-07
Deeper problems, perhaps...
%LDAPUSERS% returns nothing.
Still trying to get meaningful debug information.
The cache file created by
LdapContrib is correct -- with all the groups and users properly in the cache.db.
I turned the mapping back to Ldap, which, with user info, now properly displays my uid, my wikiname (broken) and my email address.
I'm guessing I can trace back from this error message and find whats broken.
hey, you called lookupWikiName with a loginName, referer:
https://10.10.10.10/bin/edit/Sandbox/TestTopic0?t=1278627046;nowysiwyg=1
--
DaveGroomba - 2010-07-08
I'm almost there...
Mapping works with
TwikiUsers if I manually enter addresses. That's not sustainable.
Instead, I'm trying to make wikinames in the topic via an ldap query...
Al la:
%LDAP{host="ldap.example.com" order="uid" base="ou=people,dc=example,dc=com" filter="(cn=*)" format = " * $givenName$sn - $uid - %DATE%}%
My problem is that names appear as <verbatim>$givenNameGroomba</verbatim>
Which, won't work. If I seperate out the $givenName $sn, it works, but the space between them will destroy mappings. Any idea as to how to make this work?
--
DaveGroomba - 2010-07-09
I've resorted to writing a script to pull attributes out of ldap and populating
TWikiUsers. Of course, its running out of cron.
Not the ideal solution. The frustrating thing is, a wiki I built in the 4 branch with identical configurations, did work out of the box.
--
DaveGroomba - 2010-07-12
FYI: I just ran into this same problem and fixed it with the follow modification:
--- twiki/lib/TWiki/Users/LdapUserMapping.pm.orig 2010-08-04 11:46:20.000000000 -0400
+++ twiki/lib/TWiki/Users/LdapUserMapping.pm 2010-08-04 11:47:37.000000000 -0400
@@ -361,7 +361,7 @@
=pod
----++++ getCanonicalUserID ($login) -> cUID
+---++++ login2cUID ($login) -> cUID
Convert a login name to the corresponding canonical user name.
@@ -369,7 +369,7 @@
=cut
-sub getCanonicalUserID {
+sub login2cUID {
my ($this, $login) = @_;
return $login;
--
TylerTrafford - 2010-08-04
Closing this question after more than 30 days of inactivity. Feel free to reopen if needed. Consider engaging one of the
TWiki consultants if you need timely help. We invite you to
get involved with the community, it is more likely you get community support if you support the open source project!
--
PeterThoeny - 2010-09-13
If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.