Summary
Yonyou KSOA 9.0 contains a SQL injection vulnerability in the HTTP GET parameter handler of /worksheet/worksadd.jsp, where the ID parameter is incorporated into database queries without sufficient sanitization.
A remote attacker can craft malicious requests to manipulate backend SQL statements, potentially reading, altering, or deleting data and, in some environments, escalating to full system compromise.
Affected context
The vulnerability occurs in Yonyou KSOA 9.0 within the /worksheet/worksadd.jsp endpoint when processing HTTP GET requests that include the ID parameter.
It is relevant in deployments where this JSP is exposed over a network and the application dynamically builds SQL queries using request parameters.
The risk increases when the application uses a powerful database account (e.g., with read/write or administrative privileges) and does not implement strong input validation or query parameterization for the ID value.
Exploit preconditions
- Attack surface: Network-accessible web interface exposing /worksheet/worksadd.jsp.
- Required access: Ability to send crafted HTTP GET requests (usually unauthenticated or low-privileged, depending on deployment configuration).
- Trigger point: Handling of the ID query parameter by server-side code that constructs SQL statements.
- Why exploitation is possible: The ID parameter is incorporated into SQL statements in an unsafe way (likely string concatenation) without robust validation, escaping, or parameter binding, enabling injection of attacker-controlled SQL fragments.
Why this happens
This issue maps primarily to CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection'), with a related aspect of CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component.
The underlying bug is the use of dynamically constructed SQL queries where user-controlled input (the ID HTTP GET parameter) is concatenated directly into the query text.
Because the application does not consistently enforce parameterized queries or apply rigorous server-side validation and encoding, the database interpreter receives input that blends data with control characters (quotes, operators, delimiters), allowing the attacker to alter the intended query structure.
Potential impact
- May retrieve sensitive records from database tables beyond what the application normally exposes.
- Can modify, insert, or delete application data, affecting integrity and business workflows.
- May allow extraction of authentication-related data (such as hashes or tokens) stored in the database.
- Could enable discovery of database schema and platform-specific details useful for further attacks.
- In certain configurations, can be leveraged to execute database-native commands or write files, potentially leading to remote code execution on the underlying host.
General mitigation guidance
Mitigation centers on treating all HTTP parameters as untrusted and structurally separating data from SQL logic.
Recommended design patterns include:
- Using parameterized queries / prepared statements for all database access that involves user-supplied values, including ID fields.
- Applying server-side validation for request parameters (e.g., enforcing numeric ranges or whitelisted formats for ID) and rejecting invalid input early.
- Avoiding dynamic query construction based on raw request parameters; where dynamic behavior is required, restrict it to controlled, whitelisted values.
- Assigning least-privilege roles to database accounts so that even if a query is abused, it cannot perform high-impact administrative operations.
- Centralizing database access through a vetted data access layer that enforces safe query-building patterns by default.
These measures reduce the likelihood that any single parameter handling flaw can be turned into a successful SQL injection attack.
How teams detect issues like this
Effective detection usually combines code-level and runtime observations:
- Static analysis: Configure SAST tools or custom linters to flag string concatenation of request parameters into SQL queries, particularly around the /worksheet/worksadd.jsp handler and related data-access code.
- Code review: During manual review, look for JSPs or controllers reading HTTP parameters and passing them directly into query strings, as well as repetitive patterns of inline SQL in presentation-layer code.
- Database monitoring: Enable logging of executed SQL statements and alerts for anomalous patterns (e.g., always-true conditions, UNION-based queries, or unexpected schema exploration).
- Web application firewall / RASP: Use rules or policies to detect common SQL injection signatures in HTTP parameters, including the ID parameter, while recognizing that these are a backstop, not a primary fix.
Integrating these checks into CI/CD and routine security assessments can help detect similar issues earlier in the development lifecycle.

