提出 #520933: https://github.com/liweiyi/ChestnutCMS ChestnutCMS ≤1.5.3 Arbitrary file read vulnerability情報

タイトルhttps://github.com/liweiyi/ChestnutCMS ChestnutCMS ≤1.5.3 Arbitrary file read vulnerability
説明Chestnutcms has an arbitrary file read vulnerability. The /cms/file/read route can read the filePath path file. There are filtering functions FileExUtils.normalizePath(filePath); and !EDITABLE_FILE_TYPE.contains(FileExUtils.getExtension(path)) to determine whether the directory is traversed and whether the file type suffix is in the whitelist. NormalizePath can be bypassed by...../. !EDITABLE_FILE_TYPE.contains(FileExUtils.getExtension(path)) can use the folder creation function to first create a "1.txt?" directory and then use "1.txt?/...../[file]" to achieve arbitrary file read. Vulnerability cause analysis The "`FileExUtils.getExtension`" function used in the "`FileServiceImpl.java#readFile`" function of file reading can be bypassed by using "`1.txt?`”. At this time, the suffix obtained by "`FileExUtils.getExtension`" is `txt`, which is in the whitelist, but the concatenated path in the following "`new File(root + path)`" is still our malicious path.So you can read any sensitive file on the server.
ソース⚠️ https://r0ot.notion.site/ChestnutCMS-1-5-3-Arbitrary-file-read-vulnerability-1ae27d744f7f8074a169ca849e8a1d31?pvs=4
ユーザー
 sidney (UID 82628)
送信2025年03月15日 10:21 (1 年 ago)
モデレーション2025年03月28日 12:35 (13 days later)
ステータス承諾済み
VulDBエントリ301890 [ChestnutCMS 迄 1.5.3 /dev-api/cms/file/read readFile filePath ディレクトリトラバーサル]
ポイント17

Want to know what is going to be exploited?

We predict KEV entries!