-
Notifications
You must be signed in to change notification settings - Fork 250
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
[Java]: CWE-073 - File path injection with the JFinal framework #527
Comments
Your submission is now in status Test run. For information, the evaluation workflow is the following: |
Your submission is now in status Results analysis. For information, the evaluation workflow is the following: |
@luchua-bc: I have confirmed that this query finds CVE-2021-44093, but I haven't able to confirm that it finds CVE-2021-44093. These are the query results for https://lgtm.com/query/1921658844250522458/ I don't think any of those results are the vulnerability, are they? |
Thanks @kevinbackhouse for reviewing this PR. For CVE-2021-40639 with
As it's jflyfox specific, which is not generic enough, I didn't include it in the submitted query. Four results already found by the query are valid as well although the |
Your submission is now in status Query review. For information, the evaluation workflow is the following: |
Your submission is now in status Final decision. For information, the evaluation workflow is the following: |
Your submission is now in status Pay. For information, the evaluation workflow is the following: |
Created Hackerone report 1483918 for bounty 369596 : [527] [Java]: CWE-073 - File path injection with the JFinal framework |
Your submission is now in status Closed. For information, the evaluation workflow is the following: |
Thanks @xcorail for the quick turn-around and the bounty:-) |
Query PR
github/codeql#7712
Language
Java
CVE(s) ID list
CVE-2021-44093
CVE-2021-40639
CWE
CWE-073: External Control of File Name or Path
Report
External Control of File Name or Path, also called File Path Injection, is a common attack and injection attack is listed as one of the top attacks in OWASP Top Ten 2021.
Loading files based on unvalidated user-input may cause file information disclosure and uploading files with unvalidated file types to an arbitrary directory may lead to Remote Command Execution (RCE).
JFinal
is a widely used Web + ORM framework, which has 1.4K forks and 3.2k stars on GitHub. More introduction can be found atJFinal Tutorial
. Multiple CWEs have been submitted for File Path Injection attack associated with this framework.This query detects unsafe file loading/downloading operations in code repositories that consume this framework. It models
JFinal
input methods as remote flow source using the source model CSV format. It creates a separatePathSanitizer
library so that the library can be promoted as a shared lib that can be used by other queries as well. It reduces FPs by pruning the sink and testing with both real projects on GitHub and test cases customized for this query.Are you planning to discuss this vulnerability submission publicly? (Blog Post, social networks, etc).
Blog post link
No response
The text was updated successfully, but these errors were encountered: