Merge pull request #211 from anupamme/fix-repo-comfyui-custom-nodes-alekpet-v004-path-traversal-painter-node
fix: all http endpoints registered via promptserver in painter_node.py
This commit is contained in:
@@ -37,8 +37,11 @@ PREFIX = "_setting.json"
|
||||
def isFileName(filename):
|
||||
if (
|
||||
not filename
|
||||
and filename is not None
|
||||
and (type(filename) == str and filename.strip() == "")
|
||||
or not isinstance(filename, str)
|
||||
or filename.strip() == ""
|
||||
or "/" in filename
|
||||
or "\\" in filename
|
||||
or ".." in filename
|
||||
):
|
||||
print("Filename is incorrect")
|
||||
return False
|
||||
|
||||
Reference in New Issue
Block a user