Bug #78112 [Opn->Fbk]: tempnam() wrong perms on nfsv4 fs.
Edit report at https://bugs.php.net/bug.php?id=78112&edit=1
ID: 78112
Updated by: sjon@php.net
Reported by: daniele dot aluigi at semplify dot net
Summary: tempnam() wrong perms on nfsv4 fs.
-Status: Open
+Status: Feedback
Type: Bug
Package: Filesystem function related
Operating System: linux
PHP Version: 7.2.19
-Assigned To:
+Assigned To: sjon
Block user comment: N
Private report: N
New Comment:
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.
A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc. If the script requires a
database to demonstrate the issue, please make sure it creates
all necessary tables, stored procedures etc.
Please avoid embedding huge scripts into the report.
I cannot reproduce this; the following prints 0600 for me:
php -r "echo substr(sprintf('%o', fileperms(tempnam('/mnt/nfs/',
'z'))), -4);"
maybe your mount or export options are to blame?
Previous Comments:
------------------------------------------------------------------------
[2019-06-05 16:43:12] daniele dot aluigi at semplify dot net
Description:
------------
Wrong behavior using tempnam() on an nfs v4 network filesystem.
Temporary file is correctly created and returned with full path, but with wrong perms: 0000 instead
of 0600, so basically it's not writeable.
Works with the same mount options on the same FS but using nfs v3.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=78112&edit=1
Thread (6 messages)