Summary
AdminNeo contains a flaw in SQLite database-name validation that can let an authenticated SQLite user bypass an extension check through PDO_SQLite file URI names. If the application can write the resulting file under the web root and store attacker-controlled PHP source in it, the source may be executed by the web server.
Affected context
The issue affects AdminNeo versions before 5.9.1 when SQLite connections can be configured to use the PDO driver and database names are accepted through PDO_SQLite file URIs. The risk depends on the application's ability to create or write files at attacker-influenced paths, particularly paths served or interpreted by the web server.
Exploit preconditions
- Attack surface: AdminNeo's database connection and SQLite configuration functionality
- Required access: An authenticated account with the ability to use or configure SQLite connections
- Trigger point: Processing a SQLite database name through the PDO_SQLite driver
- Why exploitation is possible: The extension guard can be bypassed using file URI database names, allowing file creation and attacker-controlled content to be written where the web server may interpret it as PHP
Why this happens
The application validates SQLite database names with an extension check that does not account for PDO_SQLite file URI syntax. This permits a crafted database name to reach file-handling behavior outside the intended guard, potentially enabling creation of a file with a dangerous extension and attacker-controlled contents. This aligns with CWE-434: Unrestricted Upload of File with Dangerous Type, because the application allows content to be written as a web-executable file without adequately restricting its path and type.
Potential impact
- An attacker may execute PHP code with the privileges of the web server process
- Application data and runtime behavior could be compromised
- The web server could be used to access other resources available to its account
- A compromised application could be used as a foothold for further attacks
General mitigation guidance
Mitigation patterns include validating database names against a strict, canonical format and rejecting URI schemes or path components when they are not required. Keep database files in a dedicated location outside web-served directories, prevent user-controlled input from determining filesystem paths, and ensure writable application directories do not allow executable content. Apply least privilege to the application process and restrict which authenticated roles can configure database connections.
How teams detect issues like this
Review database-name validation and file creation paths for assumptions that can be bypassed by URI syntax, path separators, or alternate driver behavior. Static analysis and code review can look for user-controlled values reaching filesystem or database connection APIs, and for extension checks performed without canonicalization. Policy checks can restrict writable paths and prevent execution of scripts from upload or data directories; automated code review tools may help flag these patterns.

