Summary
Yonyou KSOA 9.0 contains a SQL injection vulnerability in the /kmc/save_catalog.jsp endpoint, where the catalogid HTTP GET parameter is unsafely incorporated into database queries.
A remote attacker can manipulate this parameter to alter or execute arbitrary SQL statements, potentially accessing, modifying, or deleting backend data depending on database privileges.
Affected context
The vulnerability occurs in the Yonyou KSOA 9.0 web application, specifically within the HTTP GET parameter handling of /kmc/save_catalog.jsp.
It appears when user-controlled input from the catalogid parameter is passed to the database layer without robust validation or parameterization.
Deployments that expose this endpoint over a network and rely on dynamic query construction are more likely to be affected, especially if additional access controls are weak or absent.
Exploit preconditions
- Attack surface: Public or internal web interface exposing /kmc/save_catalog.jsp
- Required access: Ability to send crafted HTTP GET requests to the vulnerable endpoint (no local access required)
- Trigger point: Processing of the catalogid query parameter within the request handler that builds and executes SQL queries
- Why exploitation is possible: The application appears to concatenate catalogid directly into SQL statements or otherwise interpolate it without using prepared statements or safe query parameterization, allowing attacker-controlled input to influence query structure.
Why this happens
The underlying issue aligns with CWE-89: Improper Neutralization of Special Elements used in an SQL Command and is related to CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component.
The HTTP GET parameter catalogid is treated as trusted and incorporated into SQL commands without sufficient neutralization, escaping, or binding as a typed parameter.
This insecure pattern of directly embedding unvalidated external input into downstream SQL execution allows attackers to inject control characters, operators, and additional statements that change the intended logic of the query.
Potential impact
- Unauthorized reading of database records that may include sensitive or personal information
- Modification or deletion of existing data, impacting integrity and business operations
- Insertion of crafted data, leading to data corruption or application misbehavior
- Potential retrieval of authentication hashes or session-related data, aiding further compromise
- In some configurations, execution of stacked queries that may alter database configuration or user privileges
General mitigation guidance
Mitigation typically focuses on isolating database logic from raw user input and enforcing strict query construction practices:
- Use parameterized queries or prepared statements for all database interactions, ensuring catalogid is bound as a value rather than concatenated into SQL strings.
- Apply strict server-side validation for catalogid, enforcing expected type, length, and format (for example, numeric-only IDs or a well-defined identifier pattern).
- Centralize database access through a safe data access layer that prohibits dynamic SQL construction with raw HTTP parameters.
- Limit database account privileges so that the application can perform only the minimal set of operations required, reducing impact if injection occurs.
- Implement defense-in-depth with input-neutralization routines and context-aware encoding tailored to SQL sinks, while not relying on escaping alone as the primary defense.
How teams detect issues like this
Detection efforts can combine code-centric and behavior-centric approaches:
- Static analysis rules tuned to flag string concatenation or interpolation involving HTTP parameters (such as catalogid) in SQL query construction.
- Manual code review focusing on JSPs and backend components that process request parameters and interact with the database, verifying use of prepared statements.
- Database monitoring and logging for anomalous queries (e.g., unexpected UNIONs, tautologies, or stacked statements) originating from the save_catalog functionality.
- Web application firewall (WAF) policies configured to detect common SQL injection patterns in query parameters and to enforce stricter rules on catalogid.
- Integration of automated security testing (DAST) into CI/CD pipelines to continuously probe for injection vectors on exposed endpoints.

