mirror of
https://github.com/zoriya/flood.git
synced 2026-06-01 18:47:44 +00:00
config: forbid non-owner access to runtime directory by default
This commit is contained in:
@@ -203,8 +203,9 @@ process.on('SIGINT', () => {
|
||||
});
|
||||
|
||||
try {
|
||||
fs.mkdirSync(path.join(argv.rundir, 'db'), {recursive: true});
|
||||
fs.mkdirSync(path.join(argv.rundir, 'temp'), {recursive: true});
|
||||
fs.mkdirSync(path.join(argv.rundir), {recursive: true, mode: 0o700});
|
||||
fs.mkdirSync(path.join(argv.rundir, 'db'));
|
||||
fs.mkdirSync(path.join(argv.rundir, 'temp'));
|
||||
} catch (error) {
|
||||
console.error('Failed to access runtime directory');
|
||||
process.exit(1);
|
||||
|
||||
Reference in New Issue
Block a user