diff options
| author | Markus Uhlin <markus@nifty-networks.net> | 2025-11-01 19:17:44 +0100 |
|---|---|---|
| committer | Markus Uhlin <markus@nifty-networks.net> | 2025-11-01 19:17:44 +0100 |
| commit | 9cc867670d3024d914b2a38e4047afd66abc24d7 (patch) | |
| tree | 024bbf78af18f6d079cae5304e71788401847a13 /FICS | |
| parent | c875326bfb48f7bba297eeb983dab04823ed0070 (diff) | |
Changed modes
Diffstat (limited to 'FICS')
| -rw-r--r-- | FICS/prep_dir_for_privdrop.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/FICS/prep_dir_for_privdrop.cpp b/FICS/prep_dir_for_privdrop.cpp index 85d3dfb..4d4478c 100644 --- a/FICS/prep_dir_for_privdrop.cpp +++ b/FICS/prep_dir_for_privdrop.cpp @@ -117,10 +117,8 @@ prep_dir_for_privdrop(const char *path) fs::recursive_directory_iterator dir_it(v_path); uid_t uid = 0; gid_t gid = 0; - constexpr mode_t dir_mode = (S_IRUSR|S_IWUSR| - S_IRGRP|S_IWGRP|S_IROTH); - constexpr mode_t file_mode = (S_IRUSR|S_IWUSR|S_IRGRP| - S_IROTH); + constexpr mode_t dir_mode = (S_IRWXU|S_IRGRP|S_IXGRP); + constexpr mode_t file_mode = (S_IRUSR|S_IWUSR|S_IRGRP); if (get_uid_and_gid(uid, gid) == -1) { throw std::runtime_error("failed to get uid/gid"); |
