cert_manager.py - Windows Compatibility Mode - os.geteuid()

Removed the need for UID in methods. They are no longer passed a specific UID rather use the global UID in util

As all functions in other classes (e.g. Accounts, crypto_util.py) etc call os.geteuid() this should work
This commit is contained in:
ahaw021 2017-07-21 16:12:09 +08:00 committed by GitHub
parent 54b87d8f2f
commit c1d0147fc0

View file

@ -101,7 +101,7 @@ def lineage_for_certname(cli_config, certname):
"""Find a lineage object with name certname."""
configs_dir = cli_config.renewal_configs_dir
# Verify the directory is there
util.make_or_verify_dir(configs_dir, mode=0o755, uid=os.geteuid())
util.make_or_verify_dir(configs_dir, mode=0o755)
try:
renewal_file = storage.renewal_file_for_certname(cli_config, certname)
except errors.CertStorageError:
@ -240,7 +240,7 @@ def _search_lineages(cli_config, func, initial_rv):
"""
configs_dir = cli_config.renewal_configs_dir
# Verify the directory is there
util.make_or_verify_dir(configs_dir, mode=0o755, uid=os.geteuid())
util.make_or_verify_dir(configs_dir, mode=0o755)
rv = initial_rv
for renewal_file in storage.renewal_conf_files(cli_config):