Executive brief
Open Source Point of Sale (OSPOS) is a web-based inventory and sales management system. A security flaw in the way the system handles item thumbnail requests allows logged-in users to access sensitive files on the server that they should not be able to see. This could lead to the exposure of configuration files, encryption keys, or other internal system data, potentially compromising the entire installation.
Technical details
A path traversal vulnerability exists in the `getPicThumb` function within `app/Controllers/Items.php` of Open Source Point of Sale (OSPOS) through version 3.4.2. The application fails to sanitize the `pic_filename` parameter, allowing an authenticated attacker with access to the items module to use directory traversal sequences (e.g., `../../`) to escape the intended uploads directory. By sending a specially crafted request, an attacker can read sensitive files such as `.env` or configuration files. The issue has been addressed in commit `def0c27a0e252668df8d942fc31e16d1edfd7323` by implementing `basename()` sanitization and an extension allowlist.
Affected products
- opensourcepos Open Source Point of Sale (opensourcepos) <= 3.4.2
Timeline
- 2026-05-13: patched: Fix merged into master branch
- 2026-05-18: disclosed: Vulnerability published via VulDB/NVD
References
- https://github.com/opensourcepos/opensourcepos/commit/def0c27a0e252668df8d942fc31e16d1edfd7323
- https://github.com/opensourcepos/opensourcepos/pull/4545
- https://github.com/opensourcepos/opensourcepos/security/advisories/GHSA-xq63-3v4g-39r5
- https://vuldb.com/submit/802559
- https://vuldb.com/vuln/364435
- https://vuldb.com/vuln/364435/cti