1
0
Fork 0
mirror of https://github.com/composer/composer synced 2025-05-11 01:22:54 +00:00

Make sure the global config file is only readable by the owner

This commit is contained in:
Jordi Boggiano 2012-10-21 18:01:53 +02:00
parent 7aab7c6297
commit c53729793b
2 changed files with 7 additions and 0 deletions

View file

@ -110,6 +110,7 @@ EOT
if ($input->getOption('global') && !$this->configFile->exists()) {
touch($this->configFile->getPath());
$this->configFile->write(array('config' => new \ArrayObject));
chmod($this->configFile->getPath(), 0600);
}
if (!$this->configFile->exists()) {