Univention Bugzilla – Bug 37710
Add username field to user templates
Last modified: 2019-01-03 07:17:35 CET
It is not possible to define a username in user templates. That would be really nice to have as is could enforce specific policies for usernames, like: <firstname>[0]<lastname>[0:7]<:lower>
If I am correct, this is possible by something like the following extended attribute: -------------------- 8< -------------------- eval "$(ucr shell)" udm settings/extended_attribute create \ --ignore_exists \ --position "cn=custom attributes,cn=univention,$ldap_base" \ --set module="settings/usertemplate" \ --set ldapMapping='uid' \ --set objectClass='ShadowAccount' \ --set name='Username' \ --set shortDescription='User name' \ --set longDescription='User name' \ --set tabName='General' \ --set tabPosition=1 \ --set tabAdvanced=0 \ --set overwriteTab='0' \ --set valueRequired='0' \ --set CLIName='username' \ --set syntax='string' \ --set mayChange='1' \ --set multivalue='0' \ --set hook='None' -------------------- 8< --------------------
(In reply to Alexander Kläser from comment #1) > If I am correct, this is possible by something like the following extended > attribute: Don't use ShadowAccount as the object class, because this will find the user then! Use 'univentionUserTemplate' instead!
While the extended attribute might be a workaround for bigger customers, I think that having the username created by the template without any changes would be of value to smaller and cloud customers as well, who might not be looking on how to enable it from the command line. Considering that we like to recommend templates to customers, both in presales and in the forum, I think we should tackle the issue.
Requested from UCS Technical Training 2017-12-1[23]
This issue has been filled against UCS 4.0. The maintenance with bug and security fixes for UCS 4.0 has ended on 31st of May 2016. Customers still on UCS 4.0 are encouraged to update to UCS 4.3. Please contact your partner or Univention for any questions. If this issue still occurs in newer UCS versions, please use "Clone this bug" or simply reopen the issue. In this case please provide detailed information on how this issue is affecting you.