1
votes

I am quite new in administering LDAP, but I have come quite far... On my OpenLDAP server I am using phpLDAPadmin to do the following:

I have an entry with a structural objectclass account because I need the attribute host. Now I want to add the attribute mail to this entry, but this does not appear in the list when selecting Add new attribute.

So I thought I could add the objectClass inetOrgPerson which has the attribute mail but this objectClass is not in the list of classes I can add to this entry; only non-structural classes are listed...

How can I add this attribute mail to a an entry with the structural class account ?

This is the current ldif for this user (with some parts changed/removed for privacy)

 

# Entry 1: cn=intrixius,ou=Admins,ou=Managed,dc=bla,dc=eu
dn: cn=intrixius,ou=Admins,ou=Managed,dc=bla,dc=eu
cn: intrixius
gecos: intrixius
gidnumber: 500
homedirectory: /home/intrixius
host: host1
host: host2
loginshell: /bin/bash
objectclass: top
objectclass: account
objectclass: posixAccount
objectclass: shadowAccount
objectclass: ldapPublicKey
sshpublickey: ssh-rsa ... intrixius@arch
uid: intrixius
uidnumber: 16859
userpassword: {CRYPT}$6$X...

2
Please provide more information. Which LDAP server implementation you are working with. Perhaps a LDIF of the user you are referring to. - jwilleke

2 Answers

0
votes

If you can modify the schema of your LDAP server, you could create a new auxiliary class with the attribute 'mail' and assign it to your account. Some implementations also support the 'extensibleObject' auxiliary class that allows adding all attributes that are defined in the schema.

A good overview about class types etc. can be found here

1
votes

You can't have multiple STRUCTURAL object classes unless they form a single inheritance hierarchy.