mirror of
https://github.com/9001/copyparty.git
synced 2025-08-17 09:02:15 -06:00
nosub should prevent mkdir
This commit is contained in:
parent
4adbe1b517
commit
0f2c623599
|
@ -3026,6 +3026,9 @@ class HttpCli(object):
|
||||||
self.gctx = vpath
|
self.gctx = vpath
|
||||||
vpath = undot(vpath)
|
vpath = undot(vpath)
|
||||||
vfs, rem = self.asrv.vfs.get(vpath, self.uname, False, True)
|
vfs, rem = self.asrv.vfs.get(vpath, self.uname, False, True)
|
||||||
|
if "nosub" in vfs.flags:
|
||||||
|
raise Pebkac(403, "mkdir is forbidden below this folder")
|
||||||
|
|
||||||
rem = sanitize_vpath(rem, "/")
|
rem = sanitize_vpath(rem, "/")
|
||||||
fn = vfs.canonical(rem)
|
fn = vfs.canonical(rem)
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue