Univention Bugzilla – Bug 48873
Show DN in users umc module
Last modified: 2022-11-03 14:57:38 CET
For common usecases it is necessary to copy the DN from a user. It would be very helpful to show the dn in the users umc module. Maybe at first hidden but foldable.
I would find this nice, too. As a workaround you can see the DN in the url: http://example.net/univention/management/#module=udm:users/user:0:users/user:uid=foo,cn=users,dc=dev,dc=local
A hack which provides this is currently the following extended attribute: cn=dn,cn=custom attributes,cn=univention,dc=school,dc=dev objectClass: top objectClass: univentionUDMProperty objectClass: univentionObject univentionUDMPropertyModule: users/user univentionUDMPropertyLayoutTabName: General univentionUDMPropertyCopyable: 0 univentionUDMPropertyVersion: 2 univentionUDMPropertyObjectClass: none univentionUDMPropertyLayoutTabAdvanced: 0 univentionUDMPropertyValueNotEditable: 1 univentionUDMPropertyLayoutOverwriteTab: 0 univentionUDMPropertyLayoutDisable: 0 univentionUDMPropertyTranslationTabName;entry-de-de: Allgemein univentionUDMPropertyDoNotSearch: 1 univentionUDMPropertyTranslationShortDescription;entry-de-de: eindeutiger Name (DN) univentionUDMPropertySyntax: string univentionUDMPropertyLayoutPosition: 1 univentionUDMPropertyMultivalue: 0 univentionUDMPropertyDeleteObjectClass: 0 univentionUDMPropertyValueMayChange: 0 univentionUDMPropertyShortDescription: Distinguished Name univentionObjectType: settings/extended_attribute univentionUDMPropertyTranslationLongDescription;entry-de-de: LDAP-DN dieses Objekts univentionUDMPropertyLayoutGroupPosition: 1 univentionUDMPropertyLongDescription: LDAP-DN of this object univentionUDMPropertyValueRequired: 0 univentionUDMPropertyLayoutFullWidth: 1 univentionUDMPropertyLdapMapping: $dn$ univentionUDMPropertyCLIName: $dn$ cn: dn univentionUDMPropertyLayoutGroupName: User account univentionUDMPropertyTranslationGroupName;entry-de-de: Benutzereinstellungen Might break things in future UCS versions! But I would likely see this on the left where all the other meta information like object type is shown. Should be very easy to implement.
Oh wow! Thx I'll try that. I think that risk is relatively small because extended attributes are very stable.
(In reply to Michel Smidt from comment #3) > Oh wow! Thx > I'll try that. > I think that risk is relatively small because extended attributes are very > stable. No, the $dn$ is not an attribute but a hack in UMC. If you apply this please make sure after every UCS errata update it's ensured that it's still possible to create and modify objects.
Created attachment 9912 [details] Screenshot (works also with very long DN's) Patch available in branch: fbest/48873-show-dn
An alternative which is now possible to create an extended attribute for `entryDN` which is shown a readonly input field with size=2.