mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-16 22:50:13 +01:00
🔒 Some security vulnerabilities https://github.com/siyuan-note/siyuan/issues/13426
This commit is contained in:
parent
2b5a9f9f1a
commit
e70ed57f6e
5 changed files with 28 additions and 1 deletions
|
|
@ -80,6 +80,12 @@ func renderTemplate(c *gin.Context) {
|
|||
return
|
||||
}
|
||||
|
||||
if !util.IsAbsPathInWorkspace(p) {
|
||||
ret.Code = -1
|
||||
ret.Msg = "Path [" + p + "] is not in workspace"
|
||||
return
|
||||
}
|
||||
|
||||
preview := false
|
||||
if previewArg := arg["preview"]; nil != previewArg {
|
||||
preview = previewArg.(bool)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue