Summary
A high-severity SQL injection vulnerability affects the Online Faculty Clearance System 1.0 through the id parameter processed by /delete_requirement.php.
An attacker who can reach the endpoint may manipulate this parameter to influence backend database queries, potentially enabling unauthorized data access or modification when the input is not safely handled.
Affected context
The vulnerability occurs in deployments of SourceCodester Online Faculty Clearance System 1.0 where the /delete_requirement.php endpoint is accessible and the id argument reaches database query construction without sufficient separation from SQL syntax. Risk depends on network exposure, authentication controls, database permissions, and the application's input-validation behavior.
Exploit preconditions
- Attack surface: The remotely accessible
/delete_requirement.phpendpoint - Required access: Ability to submit requests to the endpoint; authentication requirements depend on the deployment
- Trigger point: Processing of the
idargument - Why exploitation is possible: Improperly handled input may alter the intended structure or behavior of a database query
Why this happens
The underlying bug is an injection flaw in which externally controlled input is incorporated into a database query without reliable parameter separation. This allows input to be interpreted as SQL rather than solely as a data value. The issue maps primarily to CWE-89: Improper Neutralization of Special Elements used in an SQL Command (SQL Injection) and is also related to the broader injection category represented by CWE-74.
Potential impact
- An attacker may read unauthorized database records
- An attacker could modify or delete application data
- The application may disclose sensitive faculty or clearance information
- Database integrity and availability could be affected
- Compromised database privileges may enable broader application impact
General mitigation guidance
Mitigation generally focuses on ensuring that user-controlled values cannot become part of SQL syntax.
Common defensive patterns include:
- Use parameterized queries or prepared statements for database access
- Apply allowlist validation and type enforcement for identifier parameters
- Avoid constructing SQL statements through string concatenation
- Run the application database account with only the privileges it requires
- Use generic error responses while recording sufficient security-relevant details internally
- Apply centralized data-access policies so individual endpoints cannot bypass safe query handling
How teams detect issues like this
Organizations can identify SQL injection risks through:
- Static analysis rules that flag SQL string construction using request parameters
- Code review checks for concatenated or interpolated query fragments
- Dynamic application testing that monitors parameter handling and database errors
- Web application firewall or API policy rules for anomalous input targeting database syntax
- Database activity monitoring for unexpected query structures, access patterns, or destructive operations
- Automated security scanning integrated into development and review workflows

