mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Don't allow host cn to be changed (it isn't used anyway).
We are required by LDAP schema to have a cn value. Don't let users change it thinking they are actually doing something. tickets 706 and 707
This commit is contained in:
parent
2f0e8e3a3d
commit
86fe47b87d
@ -533,6 +533,8 @@ class host_mod(LDAPUpdate):
|
||||
|
||||
def pre_callback(self, ldap, dn, entry_attrs, attrs_list, *keys, **options):
|
||||
# Once a principal name is set it cannot be changed
|
||||
if 'cn' in entry_attrs:
|
||||
raise errors.ACIError(info='cn is immutable')
|
||||
if 'locality' in entry_attrs:
|
||||
entry_attrs['l'] = entry_attrs['locality']
|
||||
del entry_attrs['locality']
|
||||
|
Loading…
Reference in New Issue
Block a user