From eaa5be3eecb6a54cc4ff6469057901258cf736da Mon Sep 17 00:00:00 2001 From: John L Date: Tue, 30 Jan 2018 11:23:45 -0500 Subject: [PATCH] Remove special characters in host_add random OTP generation Fixes a regression in 4.5.0 where special character set was limited. Special characters in the OTP has caused issues in unattended installations where the OTP is not properly quoted or escaped. Expansion of the special character set in 4.5.0 release may cause existing user installation scripts to fail where they wouldn't otherwise. https://pagure.io/freeipa/issue/7380 Reviewed-By: Rob Crittenden --- ipaserver/plugins/host.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ipaserver/plugins/host.py b/ipaserver/plugins/host.py index 6487cd612..291a90a2a 100644 --- a/ipaserver/plugins/host.py +++ b/ipaserver/plugins/host.py @@ -686,7 +686,7 @@ class host_add(LDAPCreate): entry_attrs['objectclass'].remove('krbprincipal') if options.get('random'): entry_attrs['userpassword'] = ipa_generate_password( - entropy_bits=TMP_PWD_ENTROPY_BITS) + entropy_bits=TMP_PWD_ENTROPY_BITS, special=None) # save the password so it can be displayed in post_callback setattr(context, 'randompassword', entry_attrs['userpassword'])