This queue is for tickets about the File-Path CPAN distribution.

Report information
The Basics
Id:
72256
Status:
resolved
Priority:
Low/Low
Queue:

People
Owner:
RICHE [...] cpan.org
Requestors:
paolo [...] medeo.net
Cc:
AdminCc:

BugTracker
Severity:
Important
Broken in:
(no value)
Fixed in:
2.10_001



Subject: Need an option of creating directories with permissions more open than user's default mask
MIME-Version: 1.0
Content-Type: text/plain; charset="UTF-8"
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 964
I have frequently the need of creating files and directories having permissions more open than the user's default. As far as I know, Perl umask() can be used only to further restrict user's permissions. The end result of the following code is different when executed by different users (having different default mask): umask(0000); make_tree("/tmp/dir1/dir2/dir3", {mode => 0777}); This is causing several problems, since--in some cases-- the directories created are not accessible to other users. Since there is code relying on the existing behavior of 'mode', I would suggest not to modify it (otherwise it would introduce security issues in cases where one rely on this exact behavior). I rather suggest creating the new modifier 'chmod' which will change the directory permissions to the specified numeric value independently from the mask, like the Perl function chmod() does. E.g. make_tree("/tmp/dir1/dir2/dir3", {chmod => 0777}); Thanks! Paolo Amedeo
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-28443-1430598133-1985.72256-0-0@rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 61
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
Content-Type: text/plain; charset="utf-8"
Message-ID: <rt-4.0.18-10114-1435334067-151.72256-0-0@rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 109
This issue has been resolved in dev release http://search.cpan.org/~riche/File-Path/Path.pm version 2.10_001.


This service runs on Request Tracker, is sponsored by The Perl Foundation, and maintained by Best Practical Solutions.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.