]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
node.py: chmod the foolscap private key (node.pem) to 0600, since it's secret
authorBrian Warner <warner@allmydata.com>
Fri, 21 Sep 2007 23:52:55 +0000 (16:52 -0700)
committerBrian Warner <warner@allmydata.com>
Fri, 21 Sep 2007 23:52:55 +0000 (16:52 -0700)
src/allmydata/node.py

index aec6a70f96a28fbab3938d5474068e2685138d5b..f5e72770fa745052c67877c339fa5aec252040c8 100644 (file)
@@ -32,6 +32,7 @@ class Node(service.MultiService):
         self._tub_ready_observerlist = observer.OneShotObserverList()
         certfile = os.path.join(self.basedir, self.CERTFILE)
         self.tub = Tub(certFile=certfile)
+        os.chmod(certfile, 0600)
         self.tub.setOption("logLocalFailures", True)
         self.tub.setOption("logRemoteFailures", True)
         self.nodeid = b32decode(self.tub.tubID.upper()) # binary format