-
Notifications
You must be signed in to change notification settings - Fork 0
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
SQL_Injection @ /CardTypesGrid.cs #1
Comments
This was referenced Nov 3, 2023
This was referenced Nov 20, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Checkmarx (SAST): SQL_Injection
Security Issue: Read More about SQL_Injection
Applications: test_App
Checkmarx Project: apcxtest/test-repo-pub2
Repository URL: https://github.com/apcxtest/test-repo-pub2
Branch: main
Scan ID: 5072abd4-8e3e-49e3-b1b5-44426e72387c
The application's CardTypes_CreateDataSource method executes an SQL query with Fill, at line 204 of /CardTypesGrid.cs. The application constructs this SQL query by embedding an untrusted string into the query without proper sanitization. The concatenated string is submitted to the database, where it is parsed and executed accordingly.
An attacker would be able to inject arbitrary syntax and data into the SQL query, by crafting a malicious payload and providing it via the input ViewState_SortDir; this input is then read by the CardTypes_CreateDataSource method at line 169 of /CardTypesGrid.cs. This input then flows through the code, into a query and to the database server - without sanitization.
This may enable an SQL Injection attack.
Result #1:
Severity: HIGH
State: TO_VERIFY
Status: RECURRENT
Attack Vector:
1. ViewState_SortDir: /CardTypesGrid.cs[169,99]
2. ToString: /CardTypesGrid.cs[169,120]
3. sOrder: /CardTypesGrid.cs[169,36]
4. sOrder: /CardTypesGrid.cs[198,47]
5. CardTypes_sSQL: /CardTypesGrid.cs[198,4]
6. CardTypes_sSQL: /CardTypesGrid.cs[201,50]
7. OleDbDataAdapter: /CardTypesGrid.cs[201,29]
8. command: /CardTypesGrid.cs[201,19]
9. command: /CardTypesGrid.cs[204,2]
10. Fill: /CardTypesGrid.cs[204,10]
Review result in Checkmarx One: SQL_Injection
The text was updated successfully, but these errors were encountered: