From 52eee6124743041e04c5ce7503077f706d37259c Mon Sep 17 00:00:00 2001 From: Jakub Vrana Date: Fri, 27 Jun 2014 08:15:15 -0700 Subject: [PATCH] Use chmod() instead of umask() --- adminer/include/functions.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/adminer/include/functions.inc.php b/adminer/include/functions.inc.php index 8e6a35a6..7cbbc599 100644 --- a/adminer/include/functions.inc.php +++ b/adminer/include/functions.inc.php @@ -1083,9 +1083,9 @@ function password_file($create) { if ($return || !$create) { return $return; } - umask(066); $fp = @fopen($filename, "w"); // @ - can have insufficient rights //! is not atomic if ($fp) { + chmod($filename, 0600); $return = rand_string(); fwrite($fp, $return); fclose($fp);