summaryrefslogtreecommitdiff
path: root/cloudinit/config
diff options
context:
space:
mode:
authorScott Moser <smoser@ubuntu.com>2014-08-26 12:25:50 -0400
committerScott Moser <smoser@ubuntu.com>2014-08-26 12:25:50 -0400
commit190cacc430900d9d2dd4dd45c59d01e30e469720 (patch)
tree541d59e56be7b628f1a73e7762d2eb233bb216c3 /cloudinit/config
parentd723c17b7abe5263d879d748dade763034cce476 (diff)
downloadvyos-cloud-init-190cacc430900d9d2dd4dd45c59d01e30e469720.tar.gz
vyos-cloud-init-190cacc430900d9d2dd4dd45c59d01e30e469720.zip
ssh_authkey_fingerprints: fix bug that prevented disabling the module
Module intended to allow disabling by configuration, but that was broken. Now this allows: no_ssh_fingerprints = True LP: #1340903
Diffstat (limited to 'cloudinit/config')
-rw-r--r--cloudinit/config/cc_ssh_authkey_fingerprints.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/cloudinit/config/cc_ssh_authkey_fingerprints.py b/cloudinit/config/cc_ssh_authkey_fingerprints.py
index be8083db..7da62589 100644
--- a/cloudinit/config/cc_ssh_authkey_fingerprints.py
+++ b/cloudinit/config/cc_ssh_authkey_fingerprints.py
@@ -92,9 +92,10 @@ def _pprint_key_entries(user, key_fn, key_entries, hash_meth='md5',
def handle(name, cfg, cloud, log, _args):
- if 'no_ssh_fingerprints' in cfg:
+ if util.is_true(cfg.get('no_ssh_fingerprints', False)):
log.debug(("Skipping module named %s, "
"logging of ssh fingerprints disabled"), name)
+ return
hash_meth = util.get_cfg_option_str(cfg, "authkey_hash", "md5")
(users, _groups) = ds.normalize_users_groups(cfg, cloud.distro)