kadmin: do not assign passwords at realm initialization
commit410d96f480ed2f0d5896e442f63b208445a18ec0
authorLuke Howard <lukeh@padl.com>
Thu, 27 Dec 2018 05:51:08 +0000 (27 16:51 +1100)
committerLuke Howard <lukeh@padl.com>
Thu, 27 Dec 2018 06:11:27 +0000 (27 17:11 +1100)
tree6d087b37e0997473ee1e0f90024d60386d75bfeb
parentbe3836d4ca27c3c8e21db24ecb38fe6099fff195
kadmin: do not assign passwords at realm initialization

Since c6bf100b password quality checks have been moved out of kadmindd and into
libkadm5. This means that all password changes are subject to quality checks,
if enforce_on_admin_set is true (the default). In rare instances it could be
possible for realm initialization to fail because the randomly generated
passwords do not pass the password quality test. Fix this by creating
principals with no password or key, rather than with a random password.

Random *keys* continue to be set immediately after the principal is created,
and before DISALLOW_ALL_TIX is unset, so there should be no functionality or
security implications from this change. It is safe to call a server-side API
such as kadm5_s_create_principal_with_key() as local_flag is asserted to be
true.
kadmin/init.c
lib/kadm5/libkadm5srv-exports.def
lib/kadm5/version-script.map