diff --git a/lib/storage/data/file/DataFileStore.js b/lib/storage/data/file/DataFileStore.js index a17192ae3..b5fe399af 100644 --- a/lib/storage/data/file/DataFileStore.js +++ b/lib/storage/data/file/DataFileStore.js @@ -121,6 +121,9 @@ class DataFileStore { * object contents */ getFilePath(key) { + if (key.includes(path.sep) || key === '..' || key === '.') { + return ''; + } if (this.isPassthrough) { const dirname = path.resolve(this.dataPath); const filePath = path.resolve(dirname, key);