mirror of
https://github.com/ether/etherpad-lite.git
synced 2026-05-11 15:16:28 +02:00
dont allow directory traversal #2
This commit is contained in:
parent
0dfecb3af7
commit
0fa7650df8
@ -165,7 +165,6 @@ function minify(req, res, next)
|
||||
var plugin = plugins.plugins[library];
|
||||
var pluginPath = plugin.package.realPath;
|
||||
filename = path.relative(ROOT_DIR, pluginPath + libraryPath);
|
||||
filename = filename.replace(/\\/g, '/'); // Windows (safe generally?)
|
||||
} else if (LIBRARY_WHITELIST.indexOf(library) != -1) {
|
||||
// Go straight into node_modules
|
||||
// Avoid `require.resolve()`, since 'mustache' and 'mustache/index.js'
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user