Fix CAInstance.import_ra_cert for empty passwords

OpenSSL can't cope with empty files, add a newline after each password

https://pagure.io/freeipa/issue/6878

Reviewed-By: Jan Cholasta <jcholast@redhat.com>
This commit is contained in:
Stanislav Laznicka authored and Jan Cholasta committed 2017-04-20 10:20:27 +00:00
1 parent 4322b57e31
commit b38750eaa8
1 file changed
+1 -1
+1 -1
View File
@@ -690,7 +690,7 @@ class CAInstance(DogtagInstance):
Used when setting up replication
"""
with ipautil.write_tmp_file(password) as f:
with ipautil.write_tmp_file(password + '\n') as f:
pwdarg = 'file:{file}'.format(file=f.name)
# get the private key from the file
ipautil.run([paths.OPENSSL,