Mercurial > trustbridge
comparison common/util.h @ 1070:f110a3f6e387
(issue114) Fine tune ACL propagation
using mkdir_p the ACL of the parent directories would
propagate to all subdirectories and objects in the directory.
Now we only use ACL propagation in the last directory to make
sure that files we might create in that directory inherit the
correct (resitricted) ACL
author | Andre Heinecke <andre.heinecke@intevation.de> |
---|---|
date | Wed, 10 Sep 2014 16:41:36 +0200 |
parents | 78798d3af8f0 |
children | fd85a02d771d |
comparison
equal
deleted
inserted
replaced
1069:709a7633a2c6 | 1070:f110a3f6e387 |
---|---|
129 * | 129 * |
130 * Code based on msdn example: | 130 * Code based on msdn example: |
131 * http://msdn.microsoft.com/en-us/library/windows/desktop/aa446595%28v=vs.85%29.aspx | 131 * http://msdn.microsoft.com/en-us/library/windows/desktop/aa446595%28v=vs.85%29.aspx |
132 * | 132 * |
133 * @param[in] path Path of the directory to create | 133 * @param[in] path Path of the directory to create |
134 * @param[in] propagate_acl weather or not objects should inherit | |
135 * the ACL of this directory. | |
134 * | 136 * |
135 * @returns true on success of if the directory exists, false on error | 137 * @returns true on success of if the directory exists, false on error |
136 */ | 138 */ |
137 bool create_restricted_directory (LPWSTR path); | 139 bool create_restricted_directory (LPWSTR path, bool propagate_acl); |
138 | 140 |
139 /**@briefu Check the integrity level of the token | 141 /**@briefu Check the integrity level of the token |
140 * | 142 * |
141 * Returns true if the token has at least SECURITY_MANADTORY_HIGH_RID or | 143 * Returns true if the token has at least SECURITY_MANADTORY_HIGH_RID or |
142 * higher. | 144 * higher. |