summaryrefslogtreecommitdiffstats
path: root/src/config/SSSDConfig.py
diff options
context:
space:
mode:
authorStephen Gallagher <sgallagh@redhat.com>2010-03-19 14:07:00 -0400
committerStephen Gallagher <sgallagh@redhat.com>2010-03-22 08:34:16 -0400
commit369975ab6d7c45916e0e2739eb5449879c32b6f8 (patch)
tree181dfa2ef15eee86d813c9fbee3cedcef19d0dde /src/config/SSSDConfig.py
parentb3f76cd4c5cacaad7580f953f3c17ab019d89330 (diff)
downloadsssd-369975ab6d7c45916e0e2739eb5449879c32b6f8.tar.gz
sssd-369975ab6d7c45916e0e2739eb5449879c32b6f8.tar.xz
sssd-369975ab6d7c45916e0e2739eb5449879c32b6f8.zip
Ensure the SSSDConfig creates sssd.conf with the correct mode
Diffstat (limited to 'src/config/SSSDConfig.py')
-rw-r--r--src/config/SSSDConfig.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/config/SSSDConfig.py b/src/config/SSSDConfig.py
index d073a6832..84af11bf2 100644
--- a/src/config/SSSDConfig.py
+++ b/src/config/SSSDConfig.py
@@ -1194,10 +1194,12 @@ class SSSDConfig(SSSDChangeConf):
outputfile = self.configfile
# open() will raise IOError if it fails
+ old_umask = os.umask(0177)
of = open(outputfile, "wb")
output = self.dump(self.opts)
of.write(output)
of.close()
+ os.umask(old_umask)
def list_services(self):
"""