diff options
| author | Adam Ierymenko <adam.ierymenko@zerotier.com> | 2014-01-26 10:32:12 -0800 |
|---|---|---|
| committer | Adam Ierymenko <adam.ierymenko@zerotier.com> | 2014-01-26 10:32:12 -0800 |
| commit | 9d67a02b5f691583220ab858cd2c6a92079e107f (patch) | |
| tree | 0f3f0053af59cebbb3f5c329749d3523c61144d0 /node/Network.cpp | |
| parent | 22efa1ab53fcd484657161841468810b43ea1d0d (diff) | |
| download | infinitytier-9d67a02b5f691583220ab858cd2c6a92079e107f.tar.gz infinitytier-9d67a02b5f691583220ab858cd2c6a92079e107f.zip | |
Lock down individual files in networks.d instead of directory since directory ACLs are more complex on Windows.
Diffstat (limited to 'node/Network.cpp')
| -rw-r--r-- | node/Network.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/node/Network.cpp b/node/Network.cpp index 37f00625..af7623c1 100644 --- a/node/Network.cpp +++ b/node/Network.cpp @@ -116,6 +116,8 @@ void Network::setConfiguration(const Dictionary &conf,bool saveToDisk) std::string confPath(_r->homePath + ZT_PATH_SEPARATOR_S + "networks.d" + ZT_PATH_SEPARATOR_S + idString() + ".conf"); if (!Utils::writeFile(confPath.c_str(),conf.toString())) { LOG("error: unable to write network configuration file at: %s",confPath.c_str()); + } else { + Utils::lockDownFile(confPath.c_str(),false); } } } else { @@ -368,6 +370,7 @@ void Network::_dumpMulticastCerts() } fclose(mcdb); + Utils::lockDownFile(mcdbPath.c_str(),false); } } // namespace ZeroTier |
