Skip to content
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

CX XPath_Injection @ src/main/java/org/cysecurity/cspf/jvl/controller/XPathQuery.java [master] #49

Open
kmcdon83 opened this issue Sep 14, 2019 · 0 comments

Comments

@kmcdon83
Copy link

XPath_Injection issue exists @ src/main/java/org/cysecurity/cspf/jvl/controller/XPathQuery.java in branch master

The application's processRequest method constructs an XPath query, for navigating an XML document. The XPath query is created with compile, at line 30 of src\main\java\org\cysecurity\cspf\jvl\controller\XPathQuery.java, using an untrusted string embedded in the expression.  
This may enable an attacker to modify the XPath expression, leading to an XPath Injection attack. 
 
The attacker may be able to inject the modified XPath expression via user input, ""username"", which is retrieved by the application in the processRequest method, at line 30 of src\main\java\org\cysecurity\cspf\jvl\controller\XPathQuery.java. This value then flows through the code to compile, as noted.

Severity: High
CWE:643
Vulnerability details and guidance
Internal Guidance
Checkmarx
Lines: 35 36


Code (Line #35):

            String user=request.getParameter("username");

Code (Line #36):

            String pass=request.getParameter("password");

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant