It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

LDAP displayName attribute - Modify logic if it has a value

Brian Billman Jul 18, 2012

Using LDAP user directory, with Copy User on Login enabled.

Our LDAP schema has a value for displayName only if the user has a "nickname" set, and if it is set, it only has the nickname (which excludes lastname, example: William -> Will). But most users don't have that set at all, and it appears that JIRA is then creating a displayName based on firstName + lastName. If it possible to change this behavior (via a plugin?) so that if displayName is not empty, to always concatenate the lastName to it, and if it is empty, to leave the default behavior?

I realize the "best" fix would be to add a new LDAP attribute that had "(nickName Or firstName) lastName", but that may not be possible, so I'm seeing if there's another option.

Thanks!

3 answers

1 accepted

0 votes
Answer accepted
Brian Billman Jan 27, 2013

I don't see any option other than creating a plugin to handle it. I tried modifying the DB directly (via a trigger), but the application doesn't reread the value (and it ends up getting overwritten the next time the user logs in).

0 votes
Marcelo Raveli Jan 09, 2013

You can resolve this problem altering the displayName attribute on LDAP.

First you need create a .ldif file with this sequence of commands:

dn: uid=Willian,ou=People,dc=your_company,dc=com
changetype: modify
delete: displayName

after, you need execute the following command as admin ldap:

ldapmodify -D "cn=root,dc=your_company,dc=com" -h localhost -f file.ldif -W -x

now you need modify the .ldif file this way:

dn: uid=marcelo,ou=People,dc=duxus,dc=com
changetype: modify
add: displayName
displayName: William Walker

after modify, you need execute the following command as admin ldap again:

ldapmodify -D "cn=root,dc=your_company,dc=com" -h localhost -f file.ldif -W -x

Done this, you should resolve your problem.

Brian Billman Jan 14, 2013

Modifying LDAP is not an option, which is why I am asking for other options (but I agree, it would be the best and easiest way to fix). I started looking into creating a plugin that will tie JIRA into our SSO system (it seems likely the displayname would be updated there), but haven't had much time to work on it (and the documentation isn't super clear, a full example would help tremendously).

0 votes
Brian Billman Feb 03, 2013

I don't see any option other than creating a plugin to handle it. I tried modifying the DB directly (via a trigger), but the application doesn't reread the value (and it ends up getting overwritten the next time the user logs in).

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Next-gen

Introducing subtasks for breaking down work in next-gen projects

Teams break work down in order to help simplify complex tasks. This is often done iteratively, with tasks being broken down into smaller tasks and so on until the work is accurately captured in well-...

9,983 views 46 44
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you