mirror of
https://github.com/ConnectedHumber/Air-Quality-Web
synced 2024-11-22 06:23:01 +00:00
Tighten permissions on auto-generated config file
This commit is contained in:
parent
f66083575a
commit
2787ea7c4c
1 changed files with 4 additions and 1 deletions
|
@ -10,10 +10,12 @@ use \Yosymfony\Toml\TomlBuilder;
|
||||||
* Handles the loading and saving of settings from a toml file.
|
* Handles the loading and saving of settings from a toml file.
|
||||||
* Supports loading default settings from a separate file.
|
* Supports loading default settings from a separate file.
|
||||||
* @author Starbeamrainbowlabs
|
* @author Starbeamrainbowlabs
|
||||||
* @version v0.5.1
|
* @version v0.5.2
|
||||||
* @lastModified 22nd March 2017
|
* @lastModified 22nd March 2017
|
||||||
* @license https://www.mozilla.org/en-US/MPL/2.0/ Mozilla Public License 2.0
|
* @license https://www.mozilla.org/en-US/MPL/2.0/ Mozilla Public License 2.0
|
||||||
* Changelog:
|
* Changelog:
|
||||||
|
* v0.5.2 - 15th January 2018
|
||||||
|
* chmod auto-generated settings file to be 0600
|
||||||
* v0.5.1 - 14th January 2018
|
* v0.5.1 - 14th January 2018
|
||||||
* Make auto-generated settings files valid
|
* Make auto-generated settings files valid
|
||||||
* v0.5 - 9th September 2018
|
* v0.5 - 9th September 2018
|
||||||
|
@ -61,6 +63,7 @@ class TomlConfig
|
||||||
} else {
|
} else {
|
||||||
mkdir(dirname($settingsFilePath), 0750, true);
|
mkdir(dirname($settingsFilePath), 0750, true);
|
||||||
file_put_contents($settingsFilePath, "$this->customSettingsBanner\n");
|
file_put_contents($settingsFilePath, "$this->customSettingsBanner\n");
|
||||||
|
chmod($settingsFilePath, 0600);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in a new issue