Skip to content

Commit

Permalink
Harden Linux trash directories (#115)
Browse files Browse the repository at this point in the history
  • Loading branch information
dittyroma committed Jun 13, 2021
1 parent 574b4a9 commit eee1414
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/linux.js
Expand Up @@ -57,8 +57,8 @@ module.exports = async paths => {
infoPath: path.join(trashPath, 'info')
};
// TODO: Use the `fs.mkdir` with `recursive` option when targeting Node.js 12.
await makeDir(paths.filesPath);
await makeDir(paths.infoPath);
await makeDir(paths.filesPath, {mode: 0o700});
await makeDir(paths.infoPath, {mode: 0o700});
return paths;
})();
trashPathsCache.set(devId, trashPathsPromise);
Expand Down

0 comments on commit eee1414

Please sign in to comment.