Subject: Re: [Boost-bugs] [Boost C++ Libraries] #11179: create_directories() does not allow control of permissions
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2015-12-02 08:28:48
#11179: create_directories() does not allow control of permissions
----------------------------------------------+------------------------
Reporter: Michi Henning <michi.henning@â¦> | Owner: bemandawes
Type: Feature Requests | Status: new
Milestone: To Be Determined | Component: filesystem
Version: Boost 1.57.0 | Severity: Problem
Resolution: | Keywords:
----------------------------------------------+------------------------
Comment (by anonymous):
Seconded, being unable to pass permissions (and being unable to adjust the
umask) opens an attack vector, with the directory being created with wide
open permissions before being able to fix up the permissions. The
following example illustrates the issue:
{{{
fs::create_directories(p);
// There is a potential race here. Also note that
// fs::permissions only fixes up the permissions for the last directory
on the path.
fs::permissions(p, fs::perms::owner_all);
}}}
Being able to pass permissions to create_directories would help with the
race and would make it easier for developers to do the right thing (tm).
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/11179#comment:1> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:19 UTC