web: fix umask on uploader so it's group readable.
authorRusty Russell <rusty@rustcorp.com.au>
Tue, 26 Jun 2012 06:58:08 +0000 (16:28 +0930)
committerRusty Russell <rusty@rustcorp.com.au>
Tue, 26 Jun 2012 06:58:08 +0000 (16:28 +0930)
web/uploader.php.cpp

index ed7f76a65cb6ccd5f4011aa4a110dc99a3c5310b..3b494df16f4fc9e3329d1158b62d1ae0f837f5aa 100644 (file)
@@ -14,6 +14,7 @@ if ($_FILES["uploadedfile"]["error"] > 0) {
 
 $dest = tempnam($tempfolder, "upload-");
 move_uploaded_file($_FILES["uploadedfile"]["tmp_name"], $dest);
+umask 0740
 
 $subject = "CCAN: code upload by '" . $_POST['email'] . "' with name " . $_FILES["uploadedfile"]["name"];
 $message = "File type: ".$_FILES["uploadedfile"]["type"]."\n".