summaryrefslogtreecommitdiffstats
path: root/src/lib/Bcfg2/Encryption.py
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2013-01-24 13:10:00 -0500
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2013-01-24 13:10:00 -0500
commit19f14e6bd219e7761202269491f062a600a9866f (patch)
tree58f3b4ae43700a7f1e875f92bba524c888533804 /src/lib/Bcfg2/Encryption.py
parentb9f1c40d4f581a1af37b7f15a5438e19d6df618b (diff)
downloadbcfg2-19f14e6bd219e7761202269491f062a600a9866f.tar.gz
bcfg2-19f14e6bd219e7761202269491f062a600a9866f.tar.bz2
bcfg2-19f14e6bd219e7761202269491f062a600a9866f.zip
don't treat "encrypt" setting as an encryption passphrase
Diffstat (limited to 'src/lib/Bcfg2/Encryption.py')
-rwxr-xr-xsrc/lib/Bcfg2/Encryption.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/lib/Bcfg2/Encryption.py b/src/lib/Bcfg2/Encryption.py
index 1eb5aaeb2..2b4ba6237 100755
--- a/src/lib/Bcfg2/Encryption.py
+++ b/src/lib/Bcfg2/Encryption.py
@@ -36,6 +36,9 @@ CFG_SECTION = "encryption"
#: The config option used to store the algorithm
CFG_ALGORITHM = "algorithm"
+#: The config option used to store the decryption strictness
+CFG_DECRYPT = "decrypt"
+
Rand.rand_seed(os.urandom(1024))
@@ -177,7 +180,7 @@ def get_passphrases(setup):
if setup.cfp.has_section(section):
return dict([(o, setup.cfp.get(section, o))
for o in setup.cfp.options(section)
- if o != CFG_ALGORITHM])
+ if o not in [CFG_ALGORITHM, CFG_DECRYPT]])
else:
return dict()