/

CVE-2026-13486

Severity:

HIGH RISK

(7.3)

SQL Injection (CWE-89) in Class Timetabling System 1.0

CVE-2026-13486

Deferred

Vulnerability type

Category:

SQL Injection

CWE:

CWE-74, CWE-89

Impact:

Database Compromise and Potential Remote Exploitation

Severity:

HIGH RISK

(7.3)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

A SQL injection flaw in the Class and Exam Timetabling System 1.0 allows crafted input in the course_year_section parameter of /preview6.php to alter backend database queries.

When the application processes this parameter without proper neutralization, a remote attacker may read, modify, or delete data and potentially gain further access to the system.

A SQL injection flaw in the Class and Exam Timetabling System 1.0 allows crafted input in the course_year_section parameter of /preview6.php to alter backend database queries.

When the application processes this parameter without proper neutralization, a remote attacker may read, modify, or delete data and potentially gain further access to the system.

Affected context

The vulnerability occurs in web-based deployments of the SourceCodester Class and Exam Timetabling System 1.0, specifically in the /preview6.php endpoint handling the course_year_section parameter.

It is most relevant when this endpoint is exposed over a network and user-supplied values are directly incorporated into SQL statements without robust validation or parameterization.

The vulnerability occurs in web-based deployments of the SourceCodester Class and Exam Timetabling System 1.0, specifically in the /preview6.php endpoint handling the course_year_section parameter.

It is most relevant when this endpoint is exposed over a network and user-supplied values are directly incorporated into SQL statements without robust validation or parameterization.

Exploit preconditions

  • Attack surface: HTTP requests targeting /preview6.php in the Class and Exam Timetabling System web interface
  • Required access: Network access to the application; usually no special privileges beyond the ability to submit requests with course_year_section
  • Trigger point: Server-side processing of the course_year_section argument within database queries
  • Why exploitation is possible: The application appears to concatenate untrusted input into SQL statements without proper neutralization or use of parameterized queries, enabling crafted input to change query structure
  • Attack surface: HTTP requests targeting /preview6.php in the Class and Exam Timetabling System web interface
  • Required access: Network access to the application; usually no special privileges beyond the ability to submit requests with course_year_section
  • Trigger point: Server-side processing of the course_year_section argument within database queries
  • Why exploitation is possible: The application appears to concatenate untrusted input into SQL statements without proper neutralization or use of parameterized queries, enabling crafted input to change query structure

Why this happens

The underlying issue aligns with CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') and is closely related to CWE-74: Improper Neutralization of Data within Output.

The application likely builds SQL queries by directly embedding course_year_section into the command string rather than using bound parameters.

This pattern allows attackers to inject control characters and SQL syntax into otherwise data-only fields, causing the database engine to interpret user input as part of the executable query logic.

The underlying issue aligns with CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') and is closely related to CWE-74: Improper Neutralization of Data within Output.

The application likely builds SQL queries by directly embedding course_year_section into the command string rather than using bound parameters.

This pattern allows attackers to inject control characters and SQL syntax into otherwise data-only fields, causing the database engine to interpret user input as part of the executable query logic.

Potential impact

  • An attacker may query sensitive information from the database (e.g., user records, timetabling data).
  • The application could allow modification or deletion of timetable entries and related records.
  • SQL injection can lead to bypassing authentication or authorization checks if these rely on database queries.
  • Under certain configurations, an attacker may pivot from database access to broader system compromise.
  • An attacker may query sensitive information from the database (e.g., user records, timetabling data).
  • The application could allow modification or deletion of timetable entries and related records.
  • SQL injection can lead to bypassing authentication or authorization checks if these rely on database queries.
  • Under certain configurations, an attacker may pivot from database access to broader system compromise.

General mitigation guidance

Effective mitigation focuses on treating all input as untrusted and isolating it from executable SQL logic.

Pattern-based controls include:

  • Using parameterized queries or prepared statements so that user input is always handled as data, never as query structure.
  • Applying centralized input validation for parameters like course_year_section, enforcing expected formats and rejecting unexpected characters.
  • Implementing output encoding and query-building APIs that discourage manual string concatenation for SQL commands.
  • Limiting database privileges used by the application to reduce the blast radius if a query is compromised.
  • Designing the system so that dangerous database operations (such as administrative or schema changes) are not exposed to front-end workflows.

Effective mitigation focuses on treating all input as untrusted and isolating it from executable SQL logic.

Pattern-based controls include:

  • Using parameterized queries or prepared statements so that user input is always handled as data, never as query structure.
  • Applying centralized input validation for parameters like course_year_section, enforcing expected formats and rejecting unexpected characters.
  • Implementing output encoding and query-building APIs that discourage manual string concatenation for SQL commands.
  • Limiting database privileges used by the application to reduce the blast radius if a query is compromised.
  • Designing the system so that dangerous database operations (such as administrative or schema changes) are not exposed to front-end workflows.

How teams detect issues like this

Detection often relies on a combination of code-level and runtime techniques:

  • Static analysis rules that flag direct concatenation of HTTP parameters into SQL queries or the use of raw query construction APIs.
  • Targeted code reviews for database access layers, looking for inconsistent parameterization, ad hoc query assembly, and lack of input validation on key parameters.
  • Application security testing, including automated SQL injection scanners and fuzzing against endpoints like /preview6.php.
  • Policy enforcement in CI/CD pipelines that require all new data access patterns to use vetted ORM or query-builder interfaces.

Detection often relies on a combination of code-level and runtime techniques:

  • Static analysis rules that flag direct concatenation of HTTP parameters into SQL queries or the use of raw query construction APIs.
  • Targeted code reviews for database access layers, looking for inconsistent parameterization, ad hoc query assembly, and lack of input validation on key parameters.
  • Application security testing, including automated SQL injection scanners and fuzzing against endpoints like /preview6.php.
  • Policy enforcement in CI/CD pipelines that require all new data access patterns to use vetted ORM or query-builder interfaces.

Sources

SourceLink
github.comgithub.com/lffaker/cybersec/issues/5
vuldb.comvuldb.com/cve/CVE-2026-13486
vuldb.comvuldb.com/submit/838188
vuldb.comvuldb.com/vuln/374483
vuldb.comvuldb.com/vuln/374483/cti
sourcecodester.comsourcecodester.com/

Frequently asked

questions

The vulnerability affects any deployment where /preview6.php is reachable over the network and processes attacker-controlled course_year_section input, potentially exposing the underlying database to manipulation.

Typically, only network access to the web application is required. If the parameter can be supplied by unauthenticated users, exploitation may not require any login credentials.

The safest approach is to refactor all affected code paths to use parameterized queries or prepared statements and enforce strict validation on the course_year_section value so it conforms to expected formats.

Adopt a consistent data access layer that forbids raw query string construction, enforce secure coding guidelines around input handling, integrate static analysis and security testing into the development pipeline, and regularly review database interaction code for adherence to these patterns.

The vulnerability affects any deployment where /preview6.php is reachable over the network and processes attacker-controlled course_year_section input, potentially exposing the underlying database to manipulation.

Typically, only network access to the web application is required. If the parameter can be supplied by unauthenticated users, exploitation may not require any login credentials.

The safest approach is to refactor all affected code paths to use parameterized queries or prepared statements and enforce strict validation on the course_year_section value so it conforms to expected formats.

Adopt a consistent data access layer that forbids raw query string construction, enforce secure coding guidelines around input handling, integrate static analysis and security testing into the development pipeline, and regularly review database interaction code for adherence to these patterns.

Find out what's already
exploitable in your codebase.